Skip to content

Commit

Permalink
[Update] Add new message type 'tc_note' for notes
Browse files Browse the repository at this point in the history
  • Loading branch information
zoglo committed Feb 6, 2023
1 parent 08d3271 commit be9eb43
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 1 deletion.
1 change: 1 addition & 0 deletions contao/classes/FileCompiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ class FileCompiler
const MSG_SUCCESS = 'tc_success';
const MSG_WARN = 'tc_warn';
const MSG_ERROR = 'tc_error';
const MSG_NOTE = 'tc_note';
const FILE_EXT = '.css';

/**
Expand Down
6 changes: 6 additions & 0 deletions public/backend.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion public/backend.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions public/backend.scss
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,14 @@ $themeCompilerPath: '/bundles/contaothemecompiler/';
}
}

&.tc_note {
color: #2c8ec7;

&:before {
background: url($themeCompilerPath + "icons/file_note.svg");
}
}

&.tc_success {
color: #4cab4c;

Expand Down
3 changes: 3 additions & 0 deletions public/icons/file_note.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions src/Command/ThemeCompileCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@ protected function execute(InputInterface $input, OutputInterface $output): int
$io->warning($message);
break;

case FileCompiler::MSG_NOTE:
$io->note($message);
break;

case FileCompiler::MSG_SUCCESS:
$io->success($message);
break;
Expand Down

0 comments on commit be9eb43

Please sign in to comment.