Better waifu image style

This commit is contained in:
SillyLossy
2023-03-06 17:54:00 +02:00
parent ef94f27906
commit 3c8e70d827
2 changed files with 11 additions and 6 deletions

View File

@@ -3,7 +3,7 @@ const SETTINGS_KEY = 'extensions_memory_settings';
const UPDATE_INTERVAL = 1000;
let expressionsList = null;
let lastCharacter = null;
let lastCharacter = undefined;
let lastMessage = null;
let inApiCall = false;
@@ -93,10 +93,14 @@ function removeExpression() {
async function validateImages() {
const context = getContext();
const IMAGE_LIST = (await getExpressionsList()).map(x => `${x}.png`);
$('.expression_settings').show();
$('#image_list').empty();
if (!context.characterId) {
return;
}
const IMAGE_LIST = (await getExpressionsList()).map(x => `${x}.png`);
IMAGE_LIST.forEach((item) => {
const image = document.createElement('img');
image.src = `/characters/${context.name2}/${item}`;

View File

@@ -2,15 +2,16 @@ div.expression {
background-image: unset;
background-repeat: no-repeat;
background-size: contain;
max-width: 200px;
max-height: 300px;
background-position-y: bottom;
max-height: 90vh;
max-width: calc((100vw - 800px)/2);
width: 100%;
height: 100%;
position: fixed;
left: 0;
bottom: 0;
margin-left: 10px;
filter: drop-shadow(2px 2px 2px #cccccc80);
filter: drop-shadow(2px 2px 2px #51515199);
transition: 500ms;
}