![]('.WEB_ROOT. 'modules/core/assets/images/logo_dark.svg)
@@ -248,9 +248,9 @@ protected function output() {
'.
- '
@@ -401,10 +401,7 @@ protected function output() {
'
'.
'
'.
'
'.
- '
'.
- '
'.
- '
'.
- '';
+ '
';
if ($this->get('router_login_state')) {
$res .= '
';
@@ -506,10 +503,10 @@ class Hm_Output_header_css extends Hm_Output_Module {
*/
protected function output() {
$res = '';
- $res .= '
';
- $res .= '
';
$mods = $this->get('router_module_list');
if (DEBUG_MODE) {
+ $res .= '
';
+ $res .= '
';
foreach (glob(APP_PATH.'modules/**', GLOB_ONLYDIR | GLOB_MARK) as $name) {
$rel_name = str_replace(APP_PATH, '', $name);
$mod = str_replace(array('modules/', '/'), '', $rel_name);
@@ -544,7 +541,8 @@ class Hm_Output_page_js extends Hm_Output_Module {
protected function output() {
if (DEBUG_MODE) {
$res = '';
- $js_lib = '';
+ $js_lib = '';
+ $js_lib .= '';
$js_lib .= '';
$js_lib .= '';
$js_lib .= '';
diff --git a/modules/core/site.css b/modules/core/site.css
index b877deff38..56bdf62cbc 100644
--- a/modules/core/site.css
+++ b/modules/core/site.css
@@ -62,10 +62,8 @@ td { vertical-align: top; }
.disabled_input, input:disabled { color: #aaa !important; background-color: #ddd; }
input, option, select, button { font-size: 100%; padding: 3px; }
textarea, select, input, button { border: solid 1px #ddd; background-color: #fff; color: #333; border-radius: 3px; }
-.login_form { float: left; font-size: 90%; padding-top: 60px; height: 300px; border-radius: 0px 0px 10px 0px; margin: 0px; background-color: #f5f5f5; width: 300px; padding-left: 20px; }
+
.screen_reader { position:absolute; top:auto; width:1px; height:1px; overflow:hidden; }
-.login_form input { clear: both; float: left; padding: 4px; margin-left: 20px; margin-top: 10px; margin-bottom: 10px; }
-#username, #password { width: 200px; }
.err { color: red !important; }
.debug { color: teal; font-size: 75%; float: right; clear: both; margin: 20px; }
.inner_list a { padding-right: 5px; }
@@ -260,7 +258,6 @@ div.unseen, .unseen .subject { font-weight: 700; }
.mobile .checkbox_cell { width: 35px; }
.mobile .checkbox_cell label { width: 30px; height: 30px; }
.mobile .github_para { white-space: normal !important; }
-.mobile .login_form { margin-top: 60px; display: block; float: none; width: 100%; background-color: #fff; font-size: 130%; height: auto; }
.mobile .account_icon { width: 20px; height: 20px; }
.mobile .imap_filter { display: none; }
.mobile .list_controls { color: #777; background: linear-gradient(180deg, #fff, #fff, #f7f2ef); height: 48px; padding-left: 5px; padding-right: 5px; }
diff --git a/scripts/config_gen.php b/scripts/config_gen.php
index a77f84d091..7eb898bdc2 100644
--- a/scripts/config_gen.php
+++ b/scripts/config_gen.php
@@ -229,14 +229,18 @@ function combine_includes($js, $js_compress, $css, $css_compress, $settings) {
$js_hash = '';
$css_hash = '';
if ($css) {
- $css_out = compress($css, $css_compress);
+ $css_out = file_get_contents("vendor/twbs/bootstrap/dist/css/bootstrap.min.css");
+ $css_out .= file_get_contents("vendor/twbs/bootstrap-icons/font/bootstrap-icons.css");
+ $css_out .= compress($css, $css_compress);
$css_hash = build_integrity_hash($css_out);
file_put_contents('site.css', $css_out);
printf("site.css file created\n");
}
if ($js) {
$mods = get_modules($settings);
- $js_lib = file_get_contents("third_party/cash.min.js");
+ $js_lib = file_get_contents("vendor/twbs/bootstrap/dist/js/bootstrap.bundle.min.js") . "\n\n";
+ $js_lib .= file_get_contents("vendor/twbs/bootstrap/dist/js/bootstrap.min.js") . "\n\n";
+ $js_lib .= file_get_contents("third_party/cash.min.js");
if (in_array('sievefilters', $mods, true)) {
$js_lib .= file_get_contents("third_party/tingle.min.js");
}
@@ -290,6 +294,24 @@ function write_config_file($settings, $filters) {
printf("dynamic.php file written\n");
}
+/**
+ * Copies bootstrap icons fonts folder as it is
+ * referenced and needed by bootstrap icons css file
+ *
+ * @return void
+ */
+function append_bootstrap_icons_files() {
+ if (!is_dir("site/fonts")) {
+ mkdir('site/fonts', 0755);
+ }
+ $source_folder = 'vendor/twbs/bootstrap-icons/font/fonts/';
+ $files = glob("$source_folder*.*");
+ foreach($files as $file){
+ $dest_forlder = str_replace($source_folder, "site/fonts/", $file);
+ copy($file, $dest_forlder);
+ }
+}
+
/**
* Copies the site.js and site.css files to the site/ directory, and creates
* a production version of the index.php file.
@@ -303,6 +325,8 @@ function create_production_site($assets, $settings, $hashes) {
printf("creating production site\n");
copy('site.css', 'site/site.css');
copy('site.js', 'site/site.js');
+ append_bootstrap_icons_files();
+
$index_file = file_get_contents('index.php');
$index_file = preg_replace("/APP_PATH', ''/", "APP_PATH', '".APP_PATH."'", $index_file);
$index_file = preg_replace("/CACHE_ID', ''/", "CACHE_ID', '".urlencode(Hm_Crypt::unique_id(32))."'", $index_file);
diff --git a/tests/phpunit/modules/core/modules.php b/tests/phpunit/modules/core/modules.php
index 3f25ba709c..cfe39cdccc 100644
--- a/tests/phpunit/modules/core/modules.php
+++ b/tests/phpunit/modules/core/modules.php
@@ -774,7 +774,7 @@ public function test_msgs() {
public function test_header_start() {
$test = new Output_Test('header_start', 'core');
$res = $test->run();
- $this->assertEquals(array('
'), $res->output_response);
+ $this->assertEquals(array('
'), $res->output_response);
}
/**
* @preserveGlobalState disabled
@@ -1530,10 +1530,10 @@ public function test_page_js_debug() {
$test = new Output_Test('page_js', 'core');
$test->handler_response = array('encrypt_ajax_requests' => true, 'router_module_list' => array('foo', 'core'));
$res = $test->run();
- $this->assertEquals(array(''), $res->output_response);
+ $this->assertEquals(array(''), $res->output_response);
$test->handler_response = array('encrypt_ajax_requests' => true, 'router_module_list' => array('imap'));
$res = $test->run();
- $this->assertEquals(array(''), $res->output_response);
+ $this->assertEquals(array(''), $res->output_response);
}
/**
* @preserveGlobalState disabled