hippofish/src/client/pages/mfm-cheat-sheet.vue

355 lines
11 KiB
Vue
Raw Normal View History

2020-11-08 07:24:46 +01:00
<template>
<div class="mwysmxbg">
2021-04-15 11:02:55 +02:00
<div class="_isolated">{{ $ts._mfm.intro }}</div>
<div class="section _block">
<div class="title">{{ $ts._mfm.mention }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.mentionDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_mention"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_mention"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.hashtag }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.hashtagDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_hashtag"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_hashtag"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.url }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.urlDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_url"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_url"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.link }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.linkDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_link"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_link"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.emoji }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.emojiDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_emoji"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_emoji"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.bold }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.boldDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_bold"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_bold"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.small }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.smallDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_small"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_small"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.quote }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.quoteDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 08:14:49 +01:00
<Mfm :text="preview_quote"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_quote"><template #label>MFM</template></MkTextarea>
2020-11-08 08:14:49 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.center }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.centerDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_center"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_center"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.inlineCode }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.inlineCodeDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_inlineCode"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_inlineCode"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.blockCode }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.blockCodeDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_blockCode"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_blockCode"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.inlineMath }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.inlineMathDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 08:14:49 +01:00
<Mfm :text="preview_inlineMath"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_inlineMath"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.search }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.searchDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_search"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_search"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.flip }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.flipDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_flip"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_flip"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.font }}</div>
<div class="content">
2020-12-31 11:42:23 +01:00
<p>{{ $ts._mfm.fontDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-12-31 11:42:23 +01:00
<Mfm :text="preview_font"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_font"><template #label>MFM</template></MkTextarea>
2020-12-31 11:42:23 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.x2 }}</div>
<div class="content">
2020-12-30 18:51:51 +01:00
<p>{{ $ts._mfm.x2Description }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-12-30 18:51:51 +01:00
<Mfm :text="preview_x2"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_x2"><template #label>MFM</template></MkTextarea>
2020-12-30 18:51:51 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.x3 }}</div>
<div class="content">
2020-12-30 18:51:51 +01:00
<p>{{ $ts._mfm.x3Description }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-12-30 18:51:51 +01:00
<Mfm :text="preview_x3"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_x3"><template #label>MFM</template></MkTextarea>
2020-12-30 18:51:51 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.x4 }}</div>
<div class="content">
2020-12-30 18:51:51 +01:00
<p>{{ $ts._mfm.x4Description }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-12-30 18:51:51 +01:00
<Mfm :text="preview_x4"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_x4"><template #label>MFM</template></MkTextarea>
2020-12-30 18:51:51 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.blur }}</div>
<div class="content">
2020-12-30 19:02:09 +01:00
<p>{{ $ts._mfm.blurDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-12-30 19:02:09 +01:00
<Mfm :text="preview_blur"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_blur"><template #label>MFM</template></MkTextarea>
2020-12-30 19:02:09 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.jelly }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.jellyDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_jelly"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_jelly"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.tada }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.tadaDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_tada"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_tada"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.jump }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.jumpDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_jump"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_jump"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.bounce }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.bounceDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 09:08:51 +01:00
<Mfm :text="preview_bounce"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_bounce"><template #label>MFM</template></MkTextarea>
2020-11-08 09:08:51 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.spin }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.spinDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_spin"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_spin"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.shake }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.shakeDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_shake"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_shake"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-04-15 11:02:55 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.twitch }}</div>
<div class="content">
2020-12-26 02:47:36 +01:00
<p>{{ $ts._mfm.twitchDescription }}</p>
2021-04-15 11:02:55 +02:00
<div class="preview">
2020-11-08 07:24:46 +01:00
<Mfm :text="preview_twitch"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_twitch"><template #label>MFM</template></MkTextarea>
2020-11-08 07:24:46 +01:00
</div>
</div>
</div>
2021-08-05 14:55:41 +02:00
<div class="section _block">
<div class="title">{{ $ts._mfm.rainbow }}</div>
<div class="content">
<p>{{ $ts._mfm.rainbowDescription }}</p>
<div class="preview">
<Mfm :text="preview_rainbow"/>
2021-08-06 15:29:19 +02:00
<MkTextarea v-model="preview_rainbow"><template #label>MFM</template></MkTextarea>
2021-08-05 14:55:41 +02:00
</div>
</div>
</div>
2020-11-08 07:24:46 +01:00
</div>
</template>
<script lang="ts">
import { defineComponent } from 'vue';
2021-03-23 09:30:14 +01:00
import MkTextarea from '@client/components/ui/textarea.vue';
2021-04-10 05:54:12 +02:00
import * as symbols from '@client/symbols';
2020-11-08 07:24:46 +01:00
export default defineComponent({
components: {
MkTextarea
},
data() {
return {
2021-04-10 05:54:12 +02:00
[symbols.PAGE_INFO]: {
2020-12-26 02:47:36 +01:00
title: this.$ts._mfm.cheatSheet,
icon: 'fas fa-question-circle',
2020-11-08 07:24:46 +01:00
},
preview_mention: '@example',
preview_hashtag: '#test',
preview_url: `https://example.com`,
2020-12-26 02:47:36 +01:00
preview_link: `[${this.$ts._mfm.dummy}](https://example.com)`,
preview_emoji: `:${this.$instance.emojis[0].name}:`,
2020-12-26 02:47:36 +01:00
preview_bold: `**${this.$ts._mfm.dummy}**`,
preview_small: `<small>${this.$ts._mfm.dummy}</small>`,
preview_center: `<center>${this.$ts._mfm.dummy}</center>`,
2020-11-08 07:24:46 +01:00
preview_inlineCode: '`<: "Hello, world!"`',
preview_blockCode: '```\n~ (#i, 100) {\n\t<: ? ((i % 15) = 0) "FizzBuzz"\n\t\t.? ((i % 3) = 0) "Fizz"\n\t\t.? ((i % 5) = 0) "Buzz"\n\t\t. i\n}\n```',
2020-11-08 08:14:49 +01:00
preview_inlineMath: '\\(x= \\frac{-b\' \\pm \\sqrt{(b\')^2-ac}}{a}\\)',
2020-12-26 02:47:36 +01:00
preview_quote: `> ${this.$ts._mfm.dummy}`,
preview_search: `${this.$ts._mfm.dummy} 検索`,
2021-04-18 09:35:34 +02:00
preview_jelly: `$[jelly 🍮]`,
preview_tada: `$[tada 🍮]`,
preview_jump: `$[jump 🍮]`,
preview_bounce: `$[bounce 🍮]`,
preview_shake: `$[shake 🍮]`,
preview_twitch: `$[twitch 🍮]`,
preview_spin: `$[spin 🍮] $[spin.left 🍮] $[spin.alternate 🍮]\n$[spin.x 🍮] $[spin.x,left 🍮] $[spin.x,alternate 🍮]\n$[spin.y 🍮] $[spin.y,left 🍮] $[spin.y,alternate 🍮]`,
preview_flip: `$[flip ${this.$ts._mfm.dummy}]\n$[flip.v ${this.$ts._mfm.dummy}]\n$[flip.h,v ${this.$ts._mfm.dummy}]`,
preview_font: `$[font.serif ${this.$ts._mfm.dummy}]\n$[font.monospace ${this.$ts._mfm.dummy}]\n$[font.cursive ${this.$ts._mfm.dummy}]\n$[font.fantasy ${this.$ts._mfm.dummy}]`,
preview_x2: `$[x2 🍮]`,
preview_x3: `$[x3 🍮]`,
preview_x4: `$[x4 🍮]`,
preview_blur: `$[blur ${this.$ts._mfm.dummy}]`,
2021-08-05 14:55:41 +02:00
preview_rainbow: `$[rainbow 🍮]`,
2020-11-08 07:24:46 +01:00
}
},
});
</script>
<style lang="scss" scoped>
.mwysmxbg {
2021-08-05 14:55:41 +02:00
background: var(--bg);
2021-04-15 11:02:55 +02:00
> .section {
> .title {
position: sticky;
z-index: 1;
top: var(--stickyTop, 0px);
padding: 16px;
font-weight: bold;
-webkit-backdrop-filter: blur(10px);
backdrop-filter: blur(10px);
background-color: var(--X16);
}
> .content {
> p {
margin: 0;
padding: 16px;
}
> .preview {
border-top: solid 0.5px var(--divider);
padding: 16px;
}
}
2020-11-08 07:24:46 +01:00
}
}
</style>