mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
Update designs
This commit is contained in:
parent
423a7f4cc9
commit
6abea7bc9c
@ -24,6 +24,7 @@ use App\Utils\Ninja;
|
||||
use App\Utils\Number;
|
||||
use App\Utils\Traits\AppSetup;
|
||||
use App\Utils\Traits\MakesDates;
|
||||
use App\Utils\Traits\MakesHash;
|
||||
use Exception;
|
||||
use Illuminate\Support\Facades\App;
|
||||
use Illuminate\Support\Facades\Cache;
|
||||
@ -32,7 +33,8 @@ class HtmlEngine
|
||||
{
|
||||
use MakesDates;
|
||||
use AppSetup;
|
||||
|
||||
use MakesHash;
|
||||
|
||||
public $entity;
|
||||
|
||||
public $invitation;
|
||||
@ -101,9 +103,9 @@ class HtmlEngine
|
||||
private function resolveCompanyLogoSize()
|
||||
{
|
||||
$design_map = [
|
||||
"VolejRejNm" => "65%", // "Plain",
|
||||
"VolejRejNm" => "5%", // "Plain",
|
||||
"Wpmbk5ezJn" => "65%", //"Clean",
|
||||
"Opnel5aKBz" => "100%", //"Bold",
|
||||
"Opnel5aKBz" => "65%", //"Bold",
|
||||
"wMvbmOeYAl" => "55%", //Modern",
|
||||
"4openRe7Az" => "65%", //"Business",
|
||||
"WJxbojagwO" => "65%", //"Creative",
|
||||
@ -112,24 +114,37 @@ class HtmlEngine
|
||||
"yMYerEdOBQ" => "65%", //"Playful",
|
||||
"gl9avmeG1v" => "65%", //"Tech",
|
||||
"7LDdwRb1YK" => "65%", //"Calm",
|
||||
"APdRoy0eGy" => "65%", //"Calm-DB2",
|
||||
"y1aK83rbQG" => "65%", //"Calm-DB1",
|
||||
];
|
||||
|
||||
if(strlen($this->settings->company_logo_size) > 1)
|
||||
{
|
||||
return $this->settings->company_logo_size;
|
||||
}
|
||||
$design_int_map = [
|
||||
"1" => "5%", // "Plain",
|
||||
"2" => "65%", //"Clean",
|
||||
"3" => "65%", //"Bold",
|
||||
"4" => "55%", //Modern",
|
||||
"5" => "65%", //"Business",
|
||||
"6" => "65%", //"Creative",
|
||||
"7" => "55%", //"Elegant",
|
||||
"8" => "65%", //"Hipster",
|
||||
"9" => "65%", //"Playful",
|
||||
"10" => "65%", //"Tech",
|
||||
"11" => "65%", //"Calm",
|
||||
"6972" => "65%", //"C-DB2"
|
||||
"11221" => "65%", //"C-DB1"
|
||||
];
|
||||
|
||||
if($this->entity->design_id && array_key_exists($this->entity->design_id, $design_map))
|
||||
{
|
||||
return $design_map[$this->entity->design_id];
|
||||
}
|
||||
if(isset($this->settings->company_logo_size) && strlen($this->settings->company_logo_size) > 1)
|
||||
return $this->settings->company_logo_size;
|
||||
|
||||
if($this->entity->design_id && array_key_exists($this->entity->design_id, $design_int_map))
|
||||
return $design_map[$this->encodePrimaryKey($this->entity->design_id)];
|
||||
|
||||
$default_design_id = $this->entity_string."_design_id";
|
||||
|
||||
$design_id = $this->settings->{$default_design_id};
|
||||
|
||||
if(array_key_exists($design_id, $design_map))
|
||||
return $design_map[$this->entity->design_id];
|
||||
return $design_map[$design_id];
|
||||
|
||||
return '65%';
|
||||
|
||||
|
@ -59,6 +59,7 @@
|
||||
.company-logo {
|
||||
height: 100%;
|
||||
max-width: 100%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
object-fit: contain;
|
||||
object-position: left center;
|
||||
}
|
||||
|
@ -41,6 +41,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.header-container > span {
|
||||
|
@ -47,6 +47,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.client-and-entity-wrapper {
|
||||
|
@ -53,6 +53,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
#company-details {
|
||||
|
@ -42,6 +42,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
#entity-details p { margin-top: 5px; }
|
||||
|
@ -32,6 +32,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 55%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
display: block;
|
||||
|
@ -81,6 +81,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.entity-label {
|
||||
|
@ -85,6 +85,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 55%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
#client-details {
|
||||
|
@ -42,6 +42,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.header-wrapper #company-address {
|
||||
|
@ -63,6 +63,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.contacts-wrapper {
|
||||
|
@ -68,6 +68,7 @@
|
||||
|
||||
.company-logo {
|
||||
max-width: 65%;
|
||||
/* max-width: $company_logo_size;*/
|
||||
}
|
||||
|
||||
.header-invoice-number {
|
||||
|
Loading…
Reference in New Issue
Block a user