This commit is contained in:
Fred Tempez 2022-03-13 14:46:39 +01:00
parent 0ad1126efa
commit 8f39d10465
5 changed files with 52 additions and 52 deletions

View File

@ -426,7 +426,7 @@ class common {
$f ['imported'] [$fontId] = [
'name' => $fontValue ['name'],
'font-family'=> $fontValue ['font-family'],
'ressource' => $fontValue ['ressource']
'resource' => $fontValue ['resource']
];
}
}
@ -438,7 +438,7 @@ class common {
$f ['files'] [$fontId] = [
'name' => $fontValue ['name'],
'font-family'=> $fontValue ['font-family'],
'ressource' => $fontValue ['ressource']
'resource' => $fontValue ['resource']
];
}
}
@ -2328,7 +2328,7 @@ class core extends common {
$fontFile = '';
foreach ($fonts as $fontId) {
if ( isset($fontsAvailable['imported'][$fontId])) {
$fontFile .= '<link href="' . $fontsAvailable['imported'][$fontId]['ressource'] .'" rel="stylesheet">';
$fontFile .= '<link href="' . $fontsAvailable['imported'][$fontId]['resource'] .'" rel="stylesheet">';
// Tableau pour la construction de la feuille de style
$fonts [$fontId] = $fontsAvailable['imported'][$fontId]['font-family'];
}
@ -2346,7 +2346,7 @@ class core extends common {
// Chargement de la police
//$formatFont = explode('.', self::DATA_DIR . 'fonts/' . $fontName);
$css .= '@font-face {font-family:"' . $fontsAvailable['files'][$fontId]['font-family'] . '";';
$css .= 'src: url("' . helper::baseUrl(false) . self::DATA_DIR . 'fonts/' .$fontsAvailable['files'][$fontId]['ressource'] . '");}';
$css .= 'src: url("' . helper::baseUrl(false) . self::DATA_DIR . 'fonts/' .$fontsAvailable['files'][$fontId]['resource'] . '");}';
// Tableau pour la construction de la feuille de style
$fonts [$fontId] = $fontsAvailable['files'][$fontId]['font-family'];
}
@ -2562,7 +2562,7 @@ class core extends common {
$fontFile = '';
foreach ($fonts as $fontId) {
if ( isset($fontsAvailable['imported'][$fontId])) {
$fontFile .= '<link href="' . $fontsAvailable['imported'][$fontId]['ressource'] .'" rel="stylesheet">';
$fontFile .= '<link href="' . $fontsAvailable['imported'][$fontId]['resource'] .'" rel="stylesheet">';
// Tableau pour la construction de la feuille de style
$fonts [$fontId] = $fontsAvailable['imported'][$fontId]['font-family'];
}
@ -2580,7 +2580,7 @@ class core extends common {
// Chargement de la police
//$formatFont = explode('.', self::DATA_DIR . 'fonts/' . $fontName);
$css .= '@font-face {font-family:"' . $fontsAvailable['files'][$fontId]['font-family'] . '";';
$css .= 'src: url("' . helper::baseUrl(false) . self::DATA_DIR . 'fonts/' .$fontsAvailable['files'][$fontId]['ressource'] . '");}';
$css .= 'src: url("' . helper::baseUrl(false) . self::DATA_DIR . 'fonts/' .$fontsAvailable['files'][$fontId]['resource'] . '");}';
// Tableau pour la construction de la feuille de style
$fonts [$fontId] = $fontsAvailable['files'][$fontId]['font-family'];
}

View File

@ -872,102 +872,102 @@ if ($this->getData(['core', 'dataVersion']) < 11400) {
'arimo'=> [
'name' => 'Arimo',
'font-family' => 'Arimo, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/arimo'
'resource' => 'https://fonts.cdnfonts.com/css/arimo'
],
'arvo'=> [
'name' => 'Arvo',
'font-family' => 'Arvo, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/arvo'
'resource' => 'https://fonts.cdnfonts.com/css/arvo'
],
'dancing-script' => [
'name' => 'Dancing Script',
'font-family' => '"Dancing Script", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/dancing-script'
'resource' => 'https://fonts.cdnfonts.com/css/dancing-script'
],
'droid-sans-2'=> [
'name' => 'Droid Sans',
'font-family' => '"Droid Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/droid-sans-2'
'resource' => 'https://fonts.cdnfonts.com/css/droid-sans-2'
],
'droid-serif-2'=> [
'name' => 'Droid Serif',
'font-family' => '"Droid Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/droid-serif-2'
'resource' => 'https://fonts.cdnfonts.com/css/droid-serif-2'
],
'indie-flower'=> [
'name' => 'Indie Flower',
'font-family' => '"Indie Flower", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/indie-flower'
'resource' => 'https://fonts.cdnfonts.com/css/indie-flower'
],
'liberation-sans'=> [
'name' => 'Liberation Sans',
'font-family' => '"Liberation Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/liberation-sans'
'resource' => 'https://fonts.cdnfonts.com/css/liberation-sans'
],
'liberation-serif'=> [
'name' => 'Liberation Serif',
'font-family' => '"Liberation Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/liberation-serif'
'resource' => 'https://fonts.cdnfonts.com/css/liberation-serif'
],
'lobster-2'=> [
'name' => 'Lobster',
'font-family' => 'Lobster, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lobster-2'
'resource' => 'https://fonts.cdnfonts.com/css/lobster-2'
],
'lato'=> [
'name' => 'lato',
'font-family' => 'Lato, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lato'
'resource' => 'https://fonts.cdnfonts.com/css/lato'
],
'lora'=> [
'name' => 'Lora',
'font-family' => 'Lora, serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lora'
'resource' => 'https://fonts.cdnfonts.com/css/lora'
],
'old-standard-tt-3'=> [
'name' => 'Old Standard TT',
'font-family' => '"Old Standard TT", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/old-standard-tt-3'
'resource' => 'https://fonts.cdnfonts.com/css/old-standard-tt-3'
],
'open-sans' => [
'name' => 'Open Sans',
'font-family' => '"Open Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/open-sans'
'resource' => 'https://fonts.cdnfonts.com/css/open-sans'
],
'oswald-4'=> [
'name' => 'Oswald',
'font-family' => 'Oswald, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/oswald-4'
'resource' => 'https://fonts.cdnfonts.com/css/oswald-4'
],
'pt-mono'=> [
'name' => 'PT Mono',
'font-family' => '"PT Mono", monospace',
'ressource' => 'https://fonts.cdnfonts.com/css/pt-mono'
'resource' => 'https://fonts.cdnfonts.com/css/pt-mono'
],
'pt-serif'=> [
'name' => "PR Serif",
'font-family' => '"PT Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/pt-serif'
'resource' => 'https://fonts.cdnfonts.com/css/pt-serif'
],
'rancho'=> [
'name' => 'Rancho',
'font-family' => 'Rancho, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/rancho'
'resource' => 'https://fonts.cdnfonts.com/css/rancho'
],
'roboto'=> [
'name' => 'Roboto',
'font-family' => 'Roboto, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/roboto'
'resource' => 'https://fonts.cdnfonts.com/css/roboto'
],
'ubuntu'=> [
'name' => 'Ubuntu',
'font-family' => 'Ubuntu, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/ubuntu'
'resource' => 'https://fonts.cdnfonts.com/css/ubuntu'
],
'vollkorn'=> [
'name' => 'Vollkorn',
'font-family' => 'Vollkorn, serif',
'ressource' => 'https://fonts.cdnfonts.com/css/vollkorn'
'resource' => 'https://fonts.cdnfonts.com/css/vollkorn'
]
];
$this->setData(['fonts', 'imported', $fonts]);

View File

@ -91,102 +91,102 @@ class init extends common {
'arimo'=> [
'name' => 'Arimo',
'font-family' => 'Arimo, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/arimo'
'resource' => 'https://fonts.cdnfonts.com/css/arimo'
],
'arvo'=> [
'name' => 'Arvo',
'font-family' => 'Arvo, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/arvo'
'resource' => 'https://fonts.cdnfonts.com/css/arvo'
],
'dancing-script' => [
'name' => 'Dancing Script',
'font-family' => '"Dancing Script", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/dancing-script'
'resource' => 'https://fonts.cdnfonts.com/css/dancing-script'
],
'droid-sans-2'=> [
'name' => 'Droid Sans',
'font-family' => '"Droid Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/droid-sans-2'
'resource' => 'https://fonts.cdnfonts.com/css/droid-sans-2'
],
'droid-serif-2'=> [
'name' => 'Droid Serif',
'font-family' => '"Droid Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/droid-serif-2'
'resource' => 'https://fonts.cdnfonts.com/css/droid-serif-2'
],
'indie-flower'=> [
'name' => 'Indie Flower',
'font-family' => '"Indie Flower", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/indie-flower'
'resource' => 'https://fonts.cdnfonts.com/css/indie-flower'
],
'liberation-sans'=> [
'name' => 'Liberation Sans',
'font-family' => '"Liberation Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/liberation-sans'
'resource' => 'https://fonts.cdnfonts.com/css/liberation-sans'
],
'liberation-serif'=> [
'name' => 'Liberation Serif',
'font-family' => '"Liberation Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/liberation-serif'
'resource' => 'https://fonts.cdnfonts.com/css/liberation-serif'
],
'lobster-2'=> [
'name' => 'Lobster',
'font-family' => 'Lobster, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lobster-2'
'resource' => 'https://fonts.cdnfonts.com/css/lobster-2'
],
'lato'=> [
'name' => 'lato',
'font-family' => 'Lato, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lato'
'resource' => 'https://fonts.cdnfonts.com/css/lato'
],
'lora'=> [
'name' => 'Lora',
'font-family' => 'Lora, serif',
'ressource' => 'https://fonts.cdnfonts.com/css/lora'
'resource' => 'https://fonts.cdnfonts.com/css/lora'
],
'old-standard-tt-3'=> [
'name' => 'Old Standard TT',
'font-family' => '"Old Standard TT", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/old-standard-tt-3'
'resource' => 'https://fonts.cdnfonts.com/css/old-standard-tt-3'
],
'open-sans' => [
'name' => 'Open Sans',
'font-family' => '"Open Sans", sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/open-sans'
'resource' => 'https://fonts.cdnfonts.com/css/open-sans'
],
'oswald-4'=> [
'name' => 'Oswald',
'font-family' => 'Oswald, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/oswald-4'
'resource' => 'https://fonts.cdnfonts.com/css/oswald-4'
],
'pt-mono'=> [
'name' => 'PT Mono',
'font-family' => '"PT Mono", monospace',
'ressource' => 'https://fonts.cdnfonts.com/css/pt-mono'
'resource' => 'https://fonts.cdnfonts.com/css/pt-mono'
],
'pt-serif'=> [
'name' => "PR Serif",
'font-family' => '"PT Serif", serif',
'ressource' => 'https://fonts.cdnfonts.com/css/pt-serif'
'resource' => 'https://fonts.cdnfonts.com/css/pt-serif'
],
'rancho'=> [
'name' => 'Rancho',
'font-family' => 'Rancho, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/rancho'
'resource' => 'https://fonts.cdnfonts.com/css/rancho'
],
'roboto'=> [
'name' => 'Roboto',
'font-family' => 'Roboto, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/roboto'
'resource' => 'https://fonts.cdnfonts.com/css/roboto'
],
'ubuntu'=> [
'name' => 'Ubuntu',
'font-family' => 'Ubuntu, sans-serif',
'ressource' => 'https://fonts.cdnfonts.com/css/ubuntu'
'resource' => 'https://fonts.cdnfonts.com/css/ubuntu'
],
'vollkorn'=> [
'name' => 'Vollkorn',
'font-family' => 'Vollkorn, serif',
'ressource' => 'https://fonts.cdnfonts.com/css/vollkorn'
'resource' => 'https://fonts.cdnfonts.com/css/vollkorn'
]
]
],

View File

@ -635,7 +635,7 @@ class theme extends common {
$t = [ $fontId => [
'name' => $fontName,
'font-family' => $fontFamilyName,
'ressource' => $ressource
'resource' => $ressource
]];
// Stocker les fontes
@ -643,7 +643,7 @@ class theme extends common {
[
'name' => $fontName,
'font-family' => $fontFamilyName,
'ressource' => $ressource
'resource' => $ressource
]]
]);
@ -691,7 +691,7 @@ class theme extends common {
$t = [ $fontId => [
'name' => $fontName,
'font-family' => $fontFamilyName,
'ressource' => $ressource
'resource' => $ressource
]];
// Stocker les fontes
@ -699,7 +699,7 @@ class theme extends common {
[
'name' => $fontName,
'font-family' => $fontFamilyName,
'ressource' => $ressource
'resource' => $ressource
]]
]);

View File

@ -69,7 +69,7 @@
<div class="col12">
<?php echo template::file('fontEditFile', [
'label' => 'Fichier de fonte (Format WOFF)',
'value' => $this->getUrl(2) === 'file' ? $this->getData(['fonts', $this->getUrl(2), $this->getUrl(3), 'ressource']) : ''
'value' => $this->getUrl(2) === 'file' ? $this->getData(['fonts', $this->getUrl(2), $this->getUrl(3), 'resource']) : ''
]); ?>
</div>
</div>
@ -77,7 +77,7 @@
<div class="col12">
<?php echo template::text('fontEditUrl', [
'label' => 'Url du fichier de fonte',
'value' => $this->getUrl(2) === 'imported' ? $this->getData(['fonts', $this->getUrl(2), $this->getUrl(3), 'ressource']) : ''
'value' => $this->getUrl(2) === 'imported' ? $this->getData(['fonts', $this->getUrl(2), $this->getUrl(3), 'resource']) : ''
]); ?>
</div>
</div>