Use tabs instead of spaces, better indentation

This commit is contained in:
Miraty 2022-05-30 20:16:36 +02:00
parent 147a25c93f
commit 68cbec8a8d
25 changed files with 1645 additions and 1674 deletions

View File

@ -110,19 +110,18 @@ if (
<meta name="application-name" content="LibreQR"> <meta name="application-name" content="LibreQR">
<meta name="referrer" content="no-referrer"> <meta name="referrer" content="no-referrer">
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src 'self' data:; style-src 'self'; form-action 'self';"> <meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src 'self' data:; style-src 'self'; form-action 'self';">
<?php <?php
require "themes/" . THEME . "/theme.php"; require "themes/" . THEME . "/theme.php";
$colorScheme['theme'] = THEME; $colorScheme['theme'] = THEME;
$options = array('cache_dir' => 'css/', 'compress' => true); $options = array('cache_dir' => 'css/', 'compress' => true);
$cssFileName = Less_Cache::Get(array("style.less" => ""), $options, $colorScheme); $cssFileName = Less_Cache::Get(array("style.less" => ""), $options, $colorScheme);
?> ?>
<link rel="stylesheet" media="screen" href="css/<?= $cssFileName ?>"> <link rel="stylesheet" media="screen" href="css/<?= $cssFileName ?>">
<?php <?php
foreach($themeDimensionsIcons as $dimFav) { // Set all icons dimensions foreach($themeDimensionsIcons as $dimFav) // Set all icons dimensions
echo ' <link rel="icon" type="image/png" href="themes/' . THEME . '/icons/' . $dimFav . '.png" sizes="' . $dimFav . 'x' . $dimFav . '">' . "\n"; echo ' <link rel="icon" type="image/png" href="themes/' . THEME . '/icons/' . $dimFav . '.png" sizes="' . $dimFav . 'x' . $dimFav . '">' . "\n";
} ?>
?>
</head> </head>
<body> <body>
@ -200,12 +199,10 @@ if (
</div> </div>
<div id="colors"> <div id="colors">
<div class="param"> <div class="param">
<label for="bgColor"><?= $loc['label_bgColor'] ?></label> <label for="bgColor"><?= $loc['label_bgColor'] ?></label>
<input type="color" name="bgColor" id="bgColor" value="#<?= htmlspecialchars($params['bgColor']) ?>"> <input type="color" name="bgColor" id="bgColor" value="#<?= htmlspecialchars($params['bgColor']) ?>">
</div> </div>
<div class="param"> <div class="param">
<label for="mainColor"><?= $loc['label_mainColor'] ?></label> <label for="mainColor"><?= $loc['label_mainColor'] ?></label>
<input type="color" name="mainColor" id="mainColor" value="#<?= htmlspecialchars($params['mainColor']) ?>"> <input type="color" name="mainColor" id="mainColor" value="#<?= htmlspecialchars($params['mainColor']) ?>">
@ -218,9 +215,9 @@ if (
</form> </form>
<?php <?php
if ($validFormSubmitted) { if ($validFormSubmitted) {
$rgbBgColor = array( $rgbBgColor = array(
'r' => hexdec(substr($params['bgColor'],0,2)), 'r' => hexdec(substr($params['bgColor'],0,2)),
@ -260,7 +257,7 @@ if (
$dataUri = $result->getDataUri(); $dataUri = $result->getDataUri();
?> ?>
<section id="output"> <section id="output">
<div class="centered" id="downloadQR"> <div class="centered" id="downloadQR">
@ -284,7 +281,7 @@ if (
</div> </div>
</section> </section>
<?php } ?> <?php } ?>
<footer> <footer>
@ -292,11 +289,11 @@ if (
<?= $loc['metaText_qr'] ?> <?= $loc['metaText_qr'] ?>
</section> </section>
<?php if (CUSTOM_TEXT_ENABLED) { ?> <?php if (CUSTOM_TEXT_ENABLED) { ?>
<section class="metaText"> <section class="metaText">
<?= CUSTOM_TEXT ?> <?= CUSTOM_TEXT ?>
</section> </section>
<?php } ?> <?php } ?>
<section class="metaText"> <section class="metaText">
<small><?= $loc['metaText_legal'] ?></small> <small><?= $loc['metaText_legal'] ?></small>

View File

@ -14,12 +14,12 @@ $loc = array(
'placeholder_pixels' => "automatic", 'placeholder_pixels' => "automatic",
'help_content' => " 'help_content' => "
<p>You can encode whatever text you want.</p> <p>You can encode whatever text you want.</p>
<p>Software which decodes these QR codes could suggest to open them with dedicated software, depending on their <a href='https://en.wikipedia.org/wiki/List_of_URI_schemes' hreflang='en' rel='help external noreferrer'>URI scheme</a>.</p> <p>Software which decodes these QR codes could suggest to open them with dedicated software, depending on their <a href='https://en.wikipedia.org/wiki/List_of_URI_schemes' hreflang='en' rel='help external noreferrer'>URI scheme</a>.</p>
<p>For instance, to open a webpage: <code>https://www.example/</code></p> <p>For instance, to open a webpage: <code>https://www.example/</code></p>
<p>To send an email: <code>mailto:contact@email.example</code></p> <p>To send an email: <code>mailto:contact@email.example</code></p>
<p>To share geographic coordinates: <code>geo:48.867564,2.364057</code></p> <p>To share geographic coordinates: <code>geo:48.867564,2.364057</code></p>
", ",
'help_redundancy' => "Redundancy is the duplication of information in the QR code to correct errors during decoding. A higher rate will produce a bigger QR code, but will have a better chance of being decoded correctly.", 'help_redundancy' => "Redundancy is the duplication of information in the QR code to correct errors during decoding. A higher rate will produce a bigger QR code, but will have a better chance of being decoded correctly.",
'help_margin' => "Number of pixels in each white band around the QR code.", 'help_margin' => "Number of pixels in each white band around the QR code.",
'help_size' => "Image width and height in pixels, without the margin.", 'help_size' => "Image width and height in pixels, without the margin.",

View File

@ -14,12 +14,12 @@ $loc = array(
'placeholder_pixels' => "automatique", 'placeholder_pixels' => "automatique",
'help_content' => " 'help_content' => "
<p>Vous pouvez encoder ce que vous voulez sous forme de texte.</p> <p>Vous pouvez encoder ce que vous voulez sous forme de texte.</p>
<p>Les logiciels qui décodent ces codes QR pourraient proposer de les ouvrir avec un logiciel dédié, en fonction de leur <a href='https://fr.wikipedia.org/wiki/Sch%C3%A9ma_d%27URI' hreflang='fr' rel='help external noreferrer'>schéma d'URI</a>.</p> <p>Les logiciels qui décodent ces codes QR pourraient proposer de les ouvrir avec un logiciel dédié, en fonction de leur <a href='https://fr.wikipedia.org/wiki/Sch%C3%A9ma_d%27URI' hreflang='fr' rel='help external noreferrer'>schéma d'URI</a>.</p>
<p>Par exemple, pour ouvrir une page Web : <code>https://www.example/</code></p> <p>Par exemple, pour ouvrir une page Web : <code>https://www.example/</code></p>
<p>Pour envoyer un mail : <code>mailto:contact@email.example</code></p> <p>Pour envoyer un mail : <code>mailto:contact@email.example</code></p>
<p>Pour partager des coordonnées géographique : <code>geo:48.867564,2.364057</code></p> <p>Pour partager des coordonnées géographique : <code>geo:48.867564,2.364057</code></p>
", ",
'help_redundancy' => "La redondance est la duplication des informations dans le code QR afin de corriger les erreurs lors du décodage. Un taux plus élevé produira un code QR plus grand, mais aura plus de chance d'être décodé correctement.", 'help_redundancy' => "La redondance est la duplication des informations dans le code QR afin de corriger les erreurs lors du décodage. Un taux plus élevé produira un code QR plus grand, mais aura plus de chance d'être décodé correctement.",
'help_margin' => "Nombre de pixels de chaque bande blanche autour du code QR.", 'help_margin' => "Nombre de pixels de chaque bande blanche autour du code QR.",
'help_size' => "Largeur et hauteur de l'image en pixels, sans la marge.", 'help_size' => "Largeur et hauteur de l'image en pixels, sans la marge.",

View File

@ -14,12 +14,12 @@ $loc = array(
'placeholder_pixels' => "auto", 'placeholder_pixels' => "auto",
'help_content' => " 'help_content' => "
<p>Podètz pas que codar lo tèxt que volètz.</p> <p>Podètz pas que codar lo tèxt que volètz.</p>
<p>Los logicials que deschifran los còdis QR poirián suggerir de los dubrir dins de logicials especials, segon lor <a href='https://en.wikipedia.org/wiki/List_of_URI_schemes' hreflang='en' rel='help external noreferrer'>esquèma URI</a>.</p> <p>Los logicials que deschifran los còdis QR poirián suggerir de los dubrir dins de logicials especials, segon lor <a href='https://en.wikipedia.org/wiki/List_of_URI_schemes' hreflang='en' rel='help external noreferrer'>esquèma URI</a>.</p>
<p>Per exemple, per dubrir la pagina web: https://www.example/</p> <p>Per exemple, per dubrir la pagina web: https://www.example/</p>
<p>Per enviar un corrièl: mailto:contact@email.example</p> <p>Per enviar un corrièl: mailto:contact@email.example</p>
<p>Per partejar de coordonadas geograficas: geo:48.867564,2.364057</p> <p>Per partejar de coordonadas geograficas: geo:48.867564,2.364057</p>
", ",
'help_redundancy' => "La redondància es la duplicacion de las informacions al còdi QR per dire de corregir las errors pendent lo deschiframent. Un taux mai naut produirà un còdi mai grand, mas serà de melhor deschifrar corrèctament.", 'help_redundancy' => "La redondància es la duplicacion de las informacions al còdi QR per dire de corregir las errors pendent lo deschiframent. Un taux mai naut produirà un còdi mai grand, mas serà de melhor deschifrar corrèctament.",
'help_margin' => "Nombre de pixèls de la banda blanca a lentorn del còdi QR.", 'help_margin' => "Nombre de pixèls de la banda blanca a lentorn del còdi QR.",
'help_size' => "Per quant deu la dimensions de limatge èsser multiplicada?", 'help_size' => "Per quant deu la dimensions de limatge èsser multiplicada?",

View File

@ -455,6 +455,7 @@ input[type=submit] {
a[download]::before { a[download]::before {
content: "💾 "; content: "💾 ";
filter: drop-shadow(-1px 1px 1px white) filter:
drop-shadow(-1px 1px 1px white)
drop-shadow(1px -1px 1px white); drop-shadow(1px -1px 1px white);
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 207 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 249 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 246 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 187 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 293 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 217 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 198 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 231 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.3 KiB

View File

@ -1,27 +0,0 @@
<?php // This file is part of LibreQR, which is distributed under the GNU AGPLv3+ license
// List icons dimensions
$themeDimensionsIcons = array(16, 32, 48, 64, 96, 128, 192, 256, 384, 512);
$colorScheme = array(
// Light theme
"bg-light" => "#14678b",
"bgField-light" => "#2186b1",
"bgTextField-light" => "#2186b1",
"bgHelp-light" => "#118abe",
"border-light" => "#42a0c8",
"borderHover-light" => "#87d1f1",
"borderFocus-light" => "#e2f6ff",
"text-light" => "#ffffff",
"secondaryText-light" => "#bbe1f1",
// Dark theme
"bg-dark" => "#14678b",
"bgField-dark" => "#2186b1",
"bgTextField-dark" => "#2186b1",
"bgHelp-dark" => "#118abe",
"border-dark" => "#42a0c8",
"borderHover-dark" => "#87d1f1",
"borderFocus-dark" => "#e2f6ff",
"text-dark" => "#ffffff",
"secondaryText-dark" => "#bbe1f1"
);

View File

@ -5,7 +5,7 @@
'type' => 'library', 'type' => 'library',
'install_path' => __DIR__ . '/../../', 'install_path' => __DIR__ . '/../../',
'aliases' => array(), 'aliases' => array(),
'reference' => '6832804dc0ad475cfe3976075eec51ae81fb6723', 'reference' => '147a25c93f60c0ff38343291c7a7819bdce7cfc4',
'name' => '__root__', 'name' => '__root__',
'dev' => true, 'dev' => true,
), ),
@ -16,7 +16,7 @@
'type' => 'library', 'type' => 'library',
'install_path' => __DIR__ . '/../../', 'install_path' => __DIR__ . '/../../',
'aliases' => array(), 'aliases' => array(),
'reference' => '6832804dc0ad475cfe3976075eec51ae81fb6723', 'reference' => '147a25c93f60c0ff38343291c7a7819bdce7cfc4',
'dev_requirement' => false, 'dev_requirement' => false,
), ),
'bacon/bacon-qr-code' => array( 'bacon/bacon-qr-code' => array(