Ever had the need to present your lines of code in a teasing fashion? Have a look at this add-on.
Installation of the Highlight File add-on works as usual. The installed block shows in the composer Blocks/Basics section.
Add a Highlight File block at any page position.
The add/edit dialogue box lets you select a file from the files uploaded to concrete5's file store:
A file is selected using concrete5's file manager. All facilities of concrete5's file manager are at your hands (for example upload of a file). Please register any unknown file types utilising concrete5's dialogue at System & Settings » Files » Allowed File Types in advance.
On selection of a file the Highlight File type is detected, if possible. The implementation supports all languages of the ace editor. The default file type txt is anticipated if automatic detection fails.
After saving the selection the file contents are shown highlighted in your page:
The grey top line containing the file name is clickable. It closes/opens the file display box. Initially the display box is open and the caret (at right) shows down. On display box closed the caret shows right.
Viewing a Highlight File block on a mobile display (bootstrap xs) the display box initially is closed.