convert background image format to WebP

This commit is contained in:
Pig Fang 2020-05-30 11:18:13 +08:00
parent 248362487f
commit 4d25b2042d
6 changed files with 4 additions and 4 deletions

View File

@ -9,7 +9,7 @@ return [
'require_verification' => 'false',
'regs_per_ip' => '3',
'announcement' => 'Welcome to Blessing Skin {version}!',
'home_pic_url' => './app/bg.png',
'home_pic_url' => './app/bg.webp',
'custom_css' => '',
'custom_js' => '',
'player_name_rule' => 'official',

View File

@ -3,5 +3,5 @@
Artisan::call('migrate', ['--force' => true]);
if (option('home_pic_url') === './app/bg.jpg') {
option(['home_pic_url' => './app/bg.png']);
option(['home_pic_url' => './app/bg.webp']);
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 425 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

View File

@ -20,7 +20,7 @@ if ($Simple) {
}
# Copy static files
Copy-Item -Path ./resources/assets/src/images/bg.png -Destination ./public/app
Copy-Item -Path ./resources/assets/src/images/bg.webp -Destination ./public/app
Copy-Item -Path ./resources/assets/src/images/favicon.ico -Destination ./public/app
Write-Host 'Static files copied.' -ForegroundColor Green

View File

@ -54,7 +54,7 @@ const config = {
],
},
{
test: /\.(png|jpg|gif)$/,
test: /\.(png|webp)$/,
loader: 'url-loader',
options: {
limit: 8192,