为 Typecho 添加 B 站蛆音娘表情

2019-07-01T08:23:00

左岸大佬扒下来的 B 站蛆音娘表情包,添加后在评论区和文章中都能使用。::quyin:maimeng::

素材上传

表情包素材 解压后上传至主题表情包目录。本主题 上传至 Typecho 根目录/usr/themes/Mirages/usr/biaoqing/Handsome 主题上传至 Typecho 根目录/usr/themes/handsome/usr/img/emotion/

配置编辑

将以下代码插入到表情包配置文件中,顺序按照喜好调整。本主题 的文件位置为 Typecho 根目录/usr/themes/Mirages/usr/biaoqing/OwO.jsonHandsome 的文件位置为 Typecho 根目录/usr/themes/handsome/usr/OwO.json

[collapse title="配置详情"]

"蛆音娘": {
    "type": "usr",
    "name": "quyin",
    "suffix": ".png",
    "retinaSuffix": ".png",
    "imgClass": "quyin",
    "container": [{
            "icon": "hematemesis",
            "text": "吐血"
        },
        {
            "icon": "1huaji",
            "text": "滑稽"
        },
        {
            "icon": "amazing",
            "text": "吃惊"
        },
        {
            "icon": "angry",
            "text": "生气"
        },
        {
            "icon": "cry",
            "text": "哭泣"
        },
        {
            "icon": "die",
            "text": "die"
        },
        {
            "icon": "doubt",
            "text": "疑问"
        },
        {
            "icon": "feizao",
            "text": "肥皂"
        },
        {
            "icon": "fue",
            "text": "扶额"
        },
        {
            "icon": "heng",
            "text": "哼"
        },
        {
            "icon": "laughing",
            "text": "大笑"
        },
        {
            "icon": "look",
            "text": "偷看"
        },
        {
            "icon": "maimeng",
            "text": "卖萌"
        },
        {
            "icon": "OK",
            "text": "OK!"
        },
        {
            "icon": "scare",
            "text": "吓死宝宝惹"
        },
        {
            "icon": "shakinghead",
            "text": "摇头"
        },
        {
            "icon": "sleep",
            "text": "睡觉"
        },
        {
            "icon": "speechless",
            "text": "无语"
        },
        {
            "icon": "watermaleon",
            "text": "吃瓜"
        },
        {
            "icon": "witty",
            "text": "机智"
        }
    ]
}

[/collapse]

修改后的配置像这样

调整大小

因为素材尺寸较大,可以使用 CSS 控制一下。对于 本主题,依次进入 控制台 - 外观 - 设置外观 - 主题自定义扩展,将代码加入到 自定义 HTML 元素拓展 - 标签: head 头部 (meta 元素后)

其他主题,加入到主题对应的 header.php 中的 </head> 标签结束前。

[tabs]

[tab title="Mirages"]

<style>
img.biaoqing.quyin {
    margin-bottom: -.3125rem;
    min-height: 3.25rem;
    height: 1em;
}
</style>

[/tab]

[tab title="Handsome"]

<style>
.emotion-quyin {
    width: 66px;
}
</style>

[/tab]

[/tabs]

本文转载自 左岸博客
当前页面是本站的「Baidu MIP」版。发表评论请点击:完整版 »