Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/moderation/src/data/checklist.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import usePermissionsStage from './stages/permissions'
import usePostApprovalStage from './stages/post-approval'
import useReReviewStage from './stages/re-review'
import useReuploadsStage from './stages/reupload'
import useDisclosuresStage from './stages/disclosures'
import useRulesStage from './stages/rules'
import useStatusAlertsStage from './stages/status-alerts'
import useSummaryStage from './stages/summary'
Expand All @@ -37,6 +38,7 @@ export function useStages(
useReuploadsStage(),
usePermissionsStage(),
useRulesStage(),
useDisclosuresStage(),
]
return [...mainStages, useStatusAlertsStage(mainStages, globalState)]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Advertisements or sponsored promotions of outside content.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- AI-generated or assisted content. </br>
Proper disclosure of AI usage is strictly required per section 6.1 of %RULES%.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- AI-generated or assisted art, assets, or other design elements.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- AI-generated or assisted code.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Functionality that relies on or is designed by generative AI.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- AI-generated or assisted writing or text, including translations.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
</br>
Don't forget to label the inclusion of:
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Being archived, or otherwise no longer receiving updates.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- Derivative content, such as code or assets from another project or creator. </br>
Per section 4 of %RULES%, you may be required to list the origin of content you did not create here if the content's license requires attribution.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
</br>
Currently, your %PROJECT_TYPE_FORMATTED_LOWER% appears to be missing disclosure of:
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## Missing Content Disclosures

Per section 5.8 of %RULES%, we ask that you ensure all applicable %PROJECT_CONTENT_DISCLOSURES_FLINK% are filled out with accurate information.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Features locked behind a paywall, donation, or other monetary exchange.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Content that may be dangerous to users with photosensitive epilepsy.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Features that interact with the user's machine outside of the context of the game.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- Telemetry or any other instances of data being sent to a remote server that the user did not connect to. </br>
Proper disclosure of data collection is strictly required per section 1.11 of %RULES%.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ Per section 2 of %RULES%, it's important that your project page accurately and h
Currently, it looks like some images do not accurately represent the content of your %PROJECT_TYPE_FORMATTED_LOWER%.
Please make sure you use authentic images such as in-game screenshots when showcasing the content or functionality of your work.

Images such as renders, AI generated or assisted images, or heavily modified images should not be used to demonstrate the functionality of your project in the %PROJECT_DESCRIPTION_FLINK% or %PROJECT_GALLERY_FLINK%.
Images such as renders, or heavily modified images should not be used to demonstrate the functionality of your project in the %PROJECT_DESCRIPTION_FLINK% or %PROJECT_GALLERY_FLINK%.

You may still include these types of branding assets or unrelated images on your project page, so long as it is clear they are not authentic representations of the content.

Per section 6.2 of %RULES%, the use of AI images is strictly prohibited.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## Insufficient Fork

This project does not appear to significantly diverge from the source work, or does not abide by the license of the source work as required by section 4 of %RULES%.
Please provide proof of your explicit permission to distribute this project from the creator(s) of the source work.
This project does not appear to significantly diverge from the source work, or does not abide by the license of the source work as required by section 4 of %RULES%. </br>
Please provide proof of your explicit permission to distribute this project from the creator(s) of the source work. </br>
Remember to appropriately credit all external content you've included or forked in your project's derivative content %PROJECT_CONTENT_DISCLOSURES_FLINK%, this may be required by the license of the source work.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
## Missing Attribution

Please ensure you've provided proper attribution to the source of all assets you have not created yourself by listing them accordingly in your project's %PROJECT_CONTENT_DISCLOSURES_FLINK%.
Per section 4 of %RULES%, this is strictly required for any content licensed with an attribution requirement clause.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## Reuploads are forbidden

This server appears to have uploaded a Modpack by another creator.
Per section 4 of %RULES%, we ask that you provide proof of your permission to distribute this pack on Modrinth.
Either implicit permission abiding by the terms of the content's license(s) or explicit permission from the original creator of the pack.
This server appears to have uploaded a Modpack by another creator. </br>
Per section 4 of %RULES%, we ask that you provide proof of your permission to distribute this pack on Modrinth. </br>
Either implicit permission abiding by the terms of the content's license(s) or explicit permission from the original creator of the pack. </br>
Please remember to appropriately credit all external content you've included or forked in your project's derivative content %PROJECT_CONTENT_DISCLOSURES_FLINK%.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## Proof of permissions

This project appears to contain content from other creators.
Per section 4 of %RULES%, we ask that you provide proof of your permission to distribute this content, or derivatives of this content in your project on Modrinth.
Either implicit permission abiding by the terms of the content's license(s) or explicit permission from the original creator of the content.
This project appears to contain content from other creators. </br>
Per section 4 of %RULES%, we ask that you provide proof of your permission to distribute this content, or derivatives of this content in your project on Modrinth. </br>
Either implicit permission abiding by the terms of the content's license(s) or explicit permission from the original creator of the content. </br>
Please remember to appropriately credit all external content you've included or forked in your project's derivative content %PROJECT_CONTENT_DISCLOSURES_FLINK%, this may be required by the license of the content.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## Reuploads are forbidden

This project appears to contain content from %ORIGINAL_PROJECT% by %ORIGINAL_AUTHOR%.
Per section 4 of %RULES%, this is strictly forbidden.
This project appears to contain content from %ORIGINAL_PROJECT% by %ORIGINAL_AUTHOR%. </br>
Per section 4 of %RULES%, this is strictly forbidden. </br>
If you believe this is an error, or you can verify you are the creator and rightful owner of this content please let us know. Otherwise, we ask that you **do not resubmit this project**.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## Forks and Reuploads

Per section 4 of %RULES%, please provide proof that this project is both license-abiding and significantly divergent from the source work.
Alternatively, please provide proof of your explicit permission from the author of the source work to distribute this content on Modrinth.
Per section 4 of %RULES%, please provide proof that this project is both license-abiding and significantly divergent from the source work. </br>
Alternatively, please provide proof of your explicit permission from the author of the source work to distribute this content on Modrinth. </br>
Please remember to appropriately credit all external content you've included or forked in your project's derivative content %PROJECT_CONTENT_DISCLOSURES_FLINK%, this may be required by the license of the source work.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## Project Withheld

Per section 6.3 of %RULES%, this project is not suitable to be published on Modrinth.

With this in mind, this project will remain unlisted, so you may still share it privately with a direct link. \
We appreciate your understanding and ask that you **do not resubmit**.
58 changes: 58 additions & 0 deletions packages/moderation/src/data/stages/disclosures.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
import { TriangleAlertIcon } from '@modrinth/assets'

import { group, option, stage, toggle } from '../../types/node'

export default function () {
return stage('disclosures', 'Disclosures')
.hint('Has this project selected all proper content disclosures?')
.guidance('https://www.notion.so/2e15ee711bf080e4a41df61bbab49892')
.icon(TriangleAlertIcon)
.navigate('/settings/disclosures')
.children(
group().children(
toggle('missing-disclosures', 'Disclosures Missing')
.message('missing-disclosures/missing-disclosures-header')
.children(
group()
.title('Which content disclosures are missing?')
.children(
toggle('ai', 'AI Usage')
.suggestedStatus('flagged')
.message()
.children(
group()
.title('What kind of AI content is present?')
.children(
toggle('code', 'Code').message('ai-usages/code'),
toggle('assets', 'Assets').message('ai-usages/assets'),
toggle('text', 'Text').message('ai-usages/text'),
toggle('functionality', 'Functionality').message('ai-usages/functionality'),
),
)
.collect(undefined, 'ai/list-intro'),

toggle('ads', 'Advertisements').suggestedStatus('flagged').message(),

toggle('paid-features', 'Paid Features').suggestedStatus('flagged').message(),

toggle('telemetry', 'Telemetry').suggestedStatus('rejected').message(),

toggle('derivative-content', 'Derivative Content')
.suggestedStatus('rejected')
.message(),

toggle('photosensitivity', 'Photosensitivity')
.suggestedStatus('rejected')
.message(),

toggle('system-interactions', 'System Interactions')
.suggestedStatus('rejected')
.message(),

toggle('archive', 'Archive').message(),
),
)
.collect(undefined, 'missing-disclosures/list-intro'),
),
)
}
1 change: 1 addition & 0 deletions packages/moderation/src/data/stages/metadata.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ export default function () {
return md('checklist/messages/metadata/environment/inaccurate', () => ({
CORRECT: correct,
}))(state)

})
.fix(
fix().project((patch, state) => {
Expand Down
7 changes: 7 additions & 0 deletions packages/moderation/src/data/stages/reupload.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,13 @@ export default function () {
OVERRIDES: state.overrides,
}))
.children(markdown('overrides').title('Forbidden overrides list').required()),

toggle('missing-attribution', 'Missing Attribution')
.suggestedStatus('rejected')
.message((state) => ({
MISSING_CREDITS: state.missing_credits,
})),
//.children(markdown('missing_credits').title('Add list of missing credits.')),
),
)
}
2 changes: 2 additions & 0 deletions packages/moderation/src/data/stages/rules.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@ export default function () {
.suggestedStatus('flagged')
.message(),

toggle('ai-generated', 'AI Generated').suggestedStatus('flagged').message(),

toggle('rule-breaking-other', 'Other')
.suggestedStatus('rejected')
.message((state) => ({ MESSAGE: state.message }))
Expand Down
4 changes: 2 additions & 2 deletions packages/moderation/src/data/stages/status-alerts.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { TriangleAlertIcon } from '@modrinth/assets'
import { MegaphoneIcon } from '@modrinth/assets'
import { injectProjectPageContext } from '@modrinth/ui'
import type { Ref } from 'vue'
import { computed } from 'vue'
Expand Down Expand Up @@ -28,7 +28,7 @@ export default function (
.guidance(
'https://www.notion.so/2e15ee711bf080e4a41df61bbab49892#2e35ee711bf080968699c397e470eca6',
)
.icon(TriangleAlertIcon)
.icon(MegaphoneIcon)
.navigate('/moderation')
.children(
() => (
Expand Down
21 changes: 11 additions & 10 deletions packages/moderation/src/types/node/capabilities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export interface Messageable {
this: this,
content: string | ((state: Record<string, NodeState>) => string | Promise<string>),
): this
collect(this: this, path?: string | (() => string) | GetVarsFn, getVars?: GetVarsFn): this
collect(this: this, fallback?: string | (() => string), prefix?: string | (() => string)): this
}

function splitPathAndVars(
Expand Down Expand Up @@ -151,17 +151,18 @@ export function withMessaging<T extends object>(node: T): T & Messageable {
},
collect(
this: Messageable,
pathOrGetVars?: string | (() => string) | GetVarsFn,
getVarsArg?: GetVarsFn,
fallbackPath?: string | (() => string),
prefixPath?: string | (() => string),
) {
const { path, getVars } = splitPathAndVars(pathOrGetVars, getVarsArg)
const fallback: MessageSegment | undefined =
path !== undefined || getVars !== undefined
? path === undefined
? { type: 'auto', ...(getVars && { getVars }) }
: { type: 'path', path, ...(getVars && { getVars }) }
: undefined
this._segments.push({ type: 'collect', ...(fallback && { fallback }) })
fallbackPath !== undefined ? { type: 'path', path: fallbackPath } : undefined
const prefix: MessageSegment | undefined =
prefixPath !== undefined ? { type: 'path', path: prefixPath } : undefined
this._segments.push({
type: 'collect',
...(fallback && { fallback }),
...(prefix && { prefix }),
})
return this
},
})
Expand Down
2 changes: 2 additions & 0 deletions packages/moderation/src/types/node/collect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ export async function evalActiveAction(
}
if (!collected.trim() && seg.fallback) {
collected = await evalSegment(seg.fallback, entry.state, entry.statePath)
} else if (collected.trim() && seg.prefix) {
collected = (await evalSegment(seg.prefix, entry.state, entry.statePath)) + collected
}
result += collected
} else {
Expand Down
2 changes: 1 addition & 1 deletion packages/moderation/src/types/node/state.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ export type MessageSegment =
| { type: 'fn'; fn: ContentFn }
| { type: 'auto'; getVars?: GetVarsFn }
| { type: 'path'; path: string | (() => string); getVars?: GetVarsFn }
| { type: 'collect'; fallback?: MessageSegment }
| { type: 'collect'; fallback?: MessageSegment; prefix?: MessageSegment }
4 changes: 4 additions & 0 deletions packages/moderation/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,10 @@ export function flattenProjectVariables(
vars[`PROJECT_MONETIZATION_SETTINGS_LINK`] = `https://modrinth.com/project/${project.id}/settings`
vars[`PROJECT_MONETIZATION_SETTINGS_FLINK`] =
`[Monetization settings](https://modrinth.com/project/${project.id}/settings)`
vars[`PROJECT_CONTENT_DISCLOSURES_LINK`] =
`https://modrinth.com/project/${project.id}/settings/disclosures`
vars[`PROJECT_CONTENT_DISCLOSURES_FLINK`] =
`[Content Disclosures](https://modrinth.com/project/${project.id}/settings/disclosures)`

return vars
}
Expand Down
Loading