refs #2606 Use vue-fontawesome in Modals/NewToot

This commit is contained in:
AkiraFukushima 2022-03-22 21:41:56 +09:00
parent e785ed2b7e
commit 180fd18d4b
No known key found for this signature in database
GPG Key ID: B6E51BAC4DE1A957
5 changed files with 16 additions and 4 deletions

View File

@ -70,6 +70,7 @@
}, },
"dependencies": { "dependencies": {
"@fortawesome/fontawesome-svg-core": "^6.1.0", "@fortawesome/fontawesome-svg-core": "^6.1.0",
"@fortawesome/free-regular-svg-icons": "^6.1.0",
"@fortawesome/free-solid-svg-icons": "^6.1.0", "@fortawesome/free-solid-svg-icons": "^6.1.0",
"@fortawesome/vue-fontawesome": "^2.0.6", "@fortawesome/vue-fontawesome": "^2.0.6",
"@panter/vue-i18next": "^0.15.2", "@panter/vue-i18next": "^0.15.2",

View File

@ -4,7 +4,7 @@
<li class="poll-option" v-for="(option, id) in value" v-bind:key="id"> <li class="poll-option" v-for="(option, id) in value" v-bind:key="id">
<el-radio :disabled="true" :label="id"> <el-radio :disabled="true" :label="id">
<el-input :placeholder="`choice ${id}`" :value="value[id]" @input="value => updateOption(value, id)" size="small"></el-input> <el-input :placeholder="`choice ${id}`" :value="value[id]" @input="value => updateOption(value, id)" size="small"></el-input>
<el-button class="remove-poll" type="text" @click="removePoll(id)" size="small"><icon name="times"></icon></el-button> <el-button class="remove-poll" type="text" @click="removePoll(id)" size="small"><font-awesome-icon icon="xmark" /></el-button>
</el-radio> </el-radio>
</li> </li>
</ul> </ul>

View File

@ -41,7 +41,7 @@
</el-popover> </el-popover>
<div v-click-outside="hideEmojiPicker"> <div v-click-outside="hideEmojiPicker">
<el-button type="text" class="emoji-selector" @click="toggleEmojiPicker"> <el-button type="text" class="emoji-selector" @click="toggleEmojiPicker">
<icon name="regular/smile" scale="1.2"></icon> <font-awesome-icon :icon="['far', 'face-smile']" size="lg" />
</el-button> </el-button>
<div v-if="openEmojiPicker" class="emoji-picker"> <div v-if="openEmojiPicker" class="emoji-picker">
<picker set="emojione" :autoFocus="true" :custom="pickerEmojis" @select="selectEmoji" /> <picker set="emojione" :autoFocus="true" :custom="pickerEmojis" @select="selectEmoji" />

View File

@ -24,8 +24,10 @@ import {
faLock, faLock,
faEyeSlash, faEyeSlash,
faEye, faEye,
faPlus faPlus,
faXmark
} from '@fortawesome/free-solid-svg-icons' } from '@fortawesome/free-solid-svg-icons'
import { faFaceSmile } from '@fortawesome/free-regular-svg-icons'
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome' import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
import 'vue-awesome/icons' import 'vue-awesome/icons'
import Icon from 'vue-awesome/components/Icon' import Icon from 'vue-awesome/components/Icon'
@ -66,7 +68,9 @@ library.add(
faLock, faLock,
faEyeSlash, faEyeSlash,
faEye, faEye,
faPlus faPlus,
faFaceSmile,
faXmark
) )
Vue.use(ElementUI, { locale }) Vue.use(ElementUI, { locale })

View File

@ -1067,6 +1067,13 @@
dependencies: dependencies:
"@fortawesome/fontawesome-common-types" "6.1.0" "@fortawesome/fontawesome-common-types" "6.1.0"
"@fortawesome/free-regular-svg-icons@^6.1.0":
version "6.1.0"
resolved "https://registry.yarnpkg.com/@fortawesome/free-regular-svg-icons/-/free-regular-svg-icons-6.1.0.tgz#5e6fb07e170a76ff8d081fb352022f933ecbb5f9"
integrity sha512-MLSBZ3AprHZXVG6zVg9Jd/mGZrlX/1jxqQsHhvZuhdRdL9bZQyXHe5RmP0n4IOth/fdnoj3fs+EnbW/O+0K4dw==
dependencies:
"@fortawesome/fontawesome-common-types" "6.1.0"
"@fortawesome/free-solid-svg-icons@^6.1.0": "@fortawesome/free-solid-svg-icons@^6.1.0":
version "6.1.0" version "6.1.0"
resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.1.0.tgz#1bdc3ce6ddd2336348ba324ac4a72161725b0d95" resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.1.0.tgz#1bdc3ce6ddd2336348ba324ac4a72161725b0d95"