fix: alt texts shouldn't be interpreted as MFM
This commit is contained in:
parent
b4cdc463a0
commit
04369c9da9
3 changed files with 8 additions and 1 deletions
|
@ -54,7 +54,8 @@
|
|||
<Mfm :text="i18n.ts.password" />
|
||||
</header>
|
||||
<div v-if="text" :class="$style.text">
|
||||
<Mfm :text="text" />
|
||||
<span v-if="isPlaintext === true">{{ text }}</span>
|
||||
<Mfm v-else :text="text" />
|
||||
</div>
|
||||
<MkInput
|
||||
v-if="input && input.type !== 'paragraph'"
|
||||
|
@ -245,6 +246,7 @@ const props = withDefaults(
|
|||
| "search";
|
||||
title: string;
|
||||
text?: string;
|
||||
isPlaintext?: boolean;
|
||||
input?: Input;
|
||||
select?: Select;
|
||||
icon?: string;
|
||||
|
@ -268,6 +270,7 @@ const props = withDefaults(
|
|||
isYesNo: false,
|
||||
|
||||
cancelableByBgClick: true,
|
||||
isPlaintext: false,
|
||||
},
|
||||
);
|
||||
|
||||
|
|
|
@ -138,6 +138,7 @@ function captionPopup() {
|
|||
os.alert({
|
||||
type: "info",
|
||||
text: props.media.comment,
|
||||
isPlaintext: true,
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -277,6 +277,7 @@ export function alert(props: {
|
|||
type?: "error" | "info" | "success" | "warning" | "waiting" | "question";
|
||||
title?: string | null;
|
||||
text?: string | null;
|
||||
isPlaintext?: boolean;
|
||||
}): Promise<void> {
|
||||
return new Promise((resolve, reject) => {
|
||||
if (props.text == null && props.type === "error") {
|
||||
|
@ -301,6 +302,7 @@ export function confirm(props: {
|
|||
text?: string | null;
|
||||
okText?: string;
|
||||
cancelText?: string;
|
||||
isPlaintext?: boolean;
|
||||
}): Promise<{ canceled: boolean }> {
|
||||
return new Promise((resolve, reject) => {
|
||||
popup(
|
||||
|
@ -323,6 +325,7 @@ export function yesno(props: {
|
|||
type: "error" | "info" | "success" | "warning" | "waiting" | "question";
|
||||
title?: string | null;
|
||||
text?: string | null;
|
||||
isPlaintext?: boolean;
|
||||
}): Promise<{ canceled: boolean }> {
|
||||
return new Promise((resolve, reject) => {
|
||||
popup(
|
||||
|
|
Loading…
Reference in a new issue