MantisBT: master e296eb4a

Author Committer Branch Timestamp Parent
dregad dregad master 2022-07-11 02:18 master 32301115
Affected Issues  0030773: Only load dynamic CSS status_config.php when necessary
Changeset

Only load status_config.php CSS when necessary

The dynamic CSS for status colors was included in relationship_api.php
and bug_group_action_api.php, which caused status_config.php to be
loaded for every MantisBT page even though it is not needed for many of
them.

This moves the require_css() call to the individual files that require
the specific color classes.

NOTE: This could introduce regression issues for Plugins relying on the
status_config.php CSS to be loaded by MantisBT core.

  • Affected plugins: relying on html_get_statuscss* functions
  • Symptoms: The status indicators are displayed in black instead of the
    expected color
  • Solution: add require_css( 'status_config.php' ); to the relevant
    plugin pages or in the EVENT_LAYOUT_RESOURCES hook, as appropriate.

Fixes 0030773

mod - bug_actiongroup.php Diff File
mod - bug_actiongroup_ext.php Diff File
mod - bug_actiongroup_ext_page.php Diff File
mod - bug_actiongroup_page.php Diff File
mod - changelog_page.php Diff File
mod - core/bug_group_action_api.php Diff File
mod - core/relationship_api.php Diff File
mod - print_all_bug_page.php Diff File
mod - roadmap_page.php Diff File