Last active
February 11, 2024 00:04
-
-
Save ItsOnlyBinary/f57d742ad0cb5a96c9bbd1e3551a0fb7 to your computer and use it in GitHub Desktop.
plugin-custom-whois.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template id="custom-whois"> | |
<div> | |
<span class="kiwi-userbox-whois-line"> | |
{{ user.away ? | |
$t('whois_status') + ': ' + user.away : | |
$t('whois_status_available') | |
}} | |
</span> | |
<span v-if="user.account" class="kiwi-userbox-whois-line"> | |
{{ $t('user_account', {user: user.account}) }} | |
</span> | |
<span class="kiwi-userbox-whois-line"> | |
{{ $t('user_realname', {realname: user.realname}) }} | |
</span> | |
<span v-if="user.whois.bot" class="kiwi-userbox-whois-line"> | |
{{ $t('user_bot') }} | |
</span> | |
<span v-if="user.whois.helpop" class="kiwi-userbox-whois-line"> | |
{{ $t('user_help') }} | |
</span> | |
<span v-if="user.whois.operator" class="kiwi-userbox-whois-line"> | |
{{ $t('user_op') }} | |
</span> | |
<span v-if="user.whois.server" class="kiwi-userbox-whois-line"> | |
{{ $t('user_server', { | |
server: user.whois.server, | |
info: (user.whois.server_info ? `(${user.whois.server_info})` : '') | |
}) }} | |
</span> | |
<span v-if="user.whois.secure" class="kiwi-userbox-whois-line"> | |
{{ $t('user_secure') }} | |
</span> | |
<span | |
v-if="user.whois.channels" | |
class="kiwi-userbox-whois-line" | |
@click="$parent.onChannelsClick($event)" | |
v-html="$t('user_channels', {channels: $parent.userChannels})" | |
/> | |
</div> | |
</template> | |
<script> | |
kiwi.plugin('custom-whois', () => { | |
const whoisComponent = { | |
template: '#custom-whois', | |
props: ['network', 'buffer', 'user'], | |
}; | |
kiwi.addUi('userbox_whois', whoisComponent); | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment