Merge pull request #55 from php-flasher/themeoptions

Override theme options
This commit is contained in:
Younes Khoubza
2022-06-04 14:57:31 +01:00
committed by GitHub
7 changed files with 11 additions and 9 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ class NotyPlugin extends Plugin
public function getScripts()
{
return array(
'https://cdn.jsdelivr.net/npm/@flasher/flasher-noty@1.0.16/dist/flasher-noty.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-noty@1.0.17/dist/flasher-noty.min.js',
);
}
}
+1 -1
View File
@@ -17,7 +17,7 @@ class NotyfPlugin extends Plugin
public function getScripts()
{
return array(
'https://cdn.jsdelivr.net/npm/@flasher/flasher-notyf@1.0.16/dist/flasher-notyf.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-notyf@1.0.17/dist/flasher-notyf.min.js',
);
}
}
+1 -1
View File
@@ -18,7 +18,7 @@ class PnotifyPlugin extends Plugin
{
return array(
'https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-pnotify@1.0.16/dist/flasher-pnotify.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-pnotify@1.0.17/dist/flasher-pnotify.min.js',
);
}
}
+1 -1
View File
@@ -43,7 +43,7 @@ class FlasherPlugin extends Plugin
*/
public function getRootScript()
{
return 'https://cdn.jsdelivr.net/npm/@flasher/flasher@1.0.16/dist/flasher.min.js';
return 'https://cdn.jsdelivr.net/npm/@flasher/flasher@1.0.17/dist/flasher.min.js';
}
/**
@@ -148,13 +148,15 @@ final class ResourceManager implements ResourceManagerInterface
*/
private function getTheme($handler)
{
if ('flasher' === $handler) {
return 'flasher';
}
if (0 === strpos($handler, 'theme.')) {
return substr($handler, \strlen('theme.'));
}
$template = key((array) $this->config->get('themes'));
return \is_string($template) ? $template : null;
return null;
}
/**
+1 -1
View File
@@ -23,7 +23,7 @@ class SweetAlertPlugin extends Plugin
{
return array(
'https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-sweetalert@1.0.16/dist/flasher-sweetalert.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-sweetalert@1.0.17/dist/flasher-sweetalert.min.js',
);
}
}
+1 -1
View File
@@ -18,7 +18,7 @@ class ToastrPlugin extends Plugin
{
return array(
'https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-toastr@1.0.16/dist/flasher-toastr.min.js',
'https://cdn.jsdelivr.net/npm/@flasher/flasher-toastr@1.0.17/dist/flasher-toastr.min.js',
);
}
}