投稿フォームにNSFWガイドラインへの導線を追加 (MisskeyIO#182)
This commit is contained in:
parent
211935640f
commit
62d26a5d0a
4 changed files with 19 additions and 4 deletions
|
|
@ -4,7 +4,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
-->
|
||||
|
||||
<template>
|
||||
<div :class="[$style.root, { [$style.warn]: warn }]">
|
||||
<div :class="[$style.root, { [$style.warn]: warn, [$style.rounded]: rounded }]">
|
||||
<i v-if="warn" class="ti ti-alert-triangle" :class="$style.i"></i>
|
||||
<i v-else class="ti ti-info-circle" :class="$style.i"></i>
|
||||
<slot></slot>
|
||||
|
|
@ -14,9 +14,12 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<script lang="ts" setup>
|
||||
import { } from 'vue';
|
||||
|
||||
const props = defineProps<{
|
||||
const props = withDefaults(defineProps<{
|
||||
warn?: boolean;
|
||||
}>();
|
||||
rounded?: boolean;
|
||||
}>(), {
|
||||
rounded: true,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" module>
|
||||
|
|
@ -25,13 +28,16 @@ const props = defineProps<{
|
|||
font-size: 90%;
|
||||
background: var(--infoBg);
|
||||
color: var(--infoFg);
|
||||
border-radius: var(--radius);
|
||||
white-space: pre-wrap;
|
||||
|
||||
&.warn {
|
||||
background: var(--infoWarnBg);
|
||||
color: var(--infoWarnFg);
|
||||
}
|
||||
|
||||
&.rounded {
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
}
|
||||
|
||||
.i {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue