moderator-toolbox-nxg-for-reddit / modules/modactions/components/FlatListModActions

modules/modactions/components/FlatListModActions

Functions

FlatListModActions()

FlatListModActions(__namedParameters): Element | null

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:151

Renders the inline mod-action buttons for a Shreddit post/comment when the viewer is a mod.

Parameters

__namedParameters

FlatListModActionsProps

Returns

Element | null

Interfaces

FlatListModActionsProps

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:47

Props for the inline mod-action row.

Properties

author?

optional author?: string

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:65

Comment author (comments only); Distinguish is only offered on the viewer’s own comments.

host?

optional host?: Element | null

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:77

The host shreddit-post/shreddit-comment element. Marked with toolbox-mod-actions-present once mod status resolves so the native-control-hiding CSS applies only where these Toolbox mod buttons actually render (see toolbox-buttons.css). Null when the ancestor couldn’t be resolved.

initialLocked?

optional initialLocked?: boolean

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:59

Initial locked state, read best-effort from the thing’s locked attribute.

initialNsfw?

optional initialNsfw?: boolean

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:57

Initial NSFW state, read from the post’s nsfw attribute (posts only).

initialStickied?

optional initialStickied?: boolean

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:61

Initial stickied state, read best-effort from the post’s stickied/pinned attribute (posts only).

isRemoved

isRemoved: boolean

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:55

Whether the thing is already removed (hides the Spam button).

isTopLevelComment?

optional isTopLevelComment?: boolean

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:71

Whether a comment is top-level (depth="0"). Only top-level comments can be distinguish-and-stickied, so the Sticky action is offered only when this is true. Comment-only; ignored for posts.

itemId

itemId: string

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:51

Fullname of the post/comment (t3_.../t1_...).

itemKind

itemKind: "post" | "comment"

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:53

Whether the thing is a post or a comment (drives which actions show).

subreddit

subreddit: string

Defined in: extension/data/modules/modactions/components/FlatListModActions.tsx:49

Subreddit the thing belongs to (no r/ prefix).