Merge branch 'main' into remote-follow

This commit is contained in:
SleeplessOne1917 2023-07-26 18:31:00 -04:00
commit ea6dcc1b01
3 changed files with 29 additions and 18 deletions

View file

@ -284,7 +284,7 @@ export class CommentNode extends Component<CommentNodeProps, CommentNodeState> {
node.comment_view.counts.child_count > 0;
return (
<li className="comment">
<li className="comment list-unstyled">
<article
id={`comment-${cv.comment.id}`}
className={classNames(`details comment-node py-2`, {
@ -348,7 +348,7 @@ export class CommentNode extends Component<CommentNodeProps, CommentNodeState> {
{showScores() && (
<>
<span
className="me-1 fw-bold"
className={`me-1 fw-bold ${this.scoreColor}`}
aria-label={I18NextService.i18n.t("number_of_points", {
count: Number(this.commentView.counts.score),
formattedCount: numToSI(this.commentView.counts.score),
@ -384,7 +384,8 @@ export class CommentNode extends Component<CommentNodeProps, CommentNodeState> {
/>
)}
{!this.state.showEdit && !this.state.collapsed && (
<div>
<>
<div className="comment-content">
{this.state.viewSource ? (
<pre>{this.commentUnlessRemoved}</pre>
) : (
@ -397,7 +398,8 @@ export class CommentNode extends Component<CommentNodeProps, CommentNodeState> {
}
/>
)}
<div className="d-flex justify-content-between justify-content-lg-start flex-wrap text-muted fw-bold">
</div>
<div className="comment-bottom-btns d-flex justify-content-between justify-content-lg-start flex-wrap text-muted fw-bold">
{this.props.showContext && this.getLinkButton()}
{this.props.markable && (
<button
@ -915,7 +917,7 @@ export class CommentNode extends Component<CommentNodeProps, CommentNodeState> {
)}
</div>
{/* end of button group */}
</div>
</>
)}
</div>
</article>

View file

@ -587,6 +587,7 @@ export class Settings extends Component<any, SettingsState> {
selectedLanguageIds={selectedLangs}
multiple={true}
showLanguageWarning={true}
showAll={true}
showSite
onChange={this.handleDiscussionLanguageChange}
/>

View file

@ -23,6 +23,14 @@ export let md: MarkdownIt = new MarkdownIt();
export let mdNoImages: MarkdownIt = new MarkdownIt();
// Zero disables all rules.
// Only explicitly allow a limited set of rules safe for use in post titles.
export const mdLimited: MarkdownIt = new MarkdownIt("zero").enable([
"emphasis",
"backticks",
"strikethrough",
]);
export const customEmojis: EmojiMartCategory[] = [];
export let customEmojisLookup: Map<string, CustomEmojiView> = new Map<
@ -43,7 +51,7 @@ export function mdToHtmlNoImages(text: string) {
}
export function mdToHtmlInline(text: string) {
return { __html: md.renderInline(text) };
return { __html: mdLimited.renderInline(text) };
}
const spoilerConfig = {