diff --git a/roentgen/moire_manager.py b/roentgen/moire_manager.py index 15a1065..9de656a 100644 --- a/roentgen/moire_manager.py +++ b/roentgen/moire_manager.py @@ -5,7 +5,7 @@ import argparse from abc import ABC from moire.moire import Tag -from moire.default import Default, DefaultMarkdown, DefaultWiki +from moire.default import Default, DefaultHTML, DefaultMarkdown, DefaultWiki from roentgen.icon import ShapeExtractor from pathlib import Path @@ -120,6 +120,41 @@ class RoentgenMoire(Default, ABC): raise NotImplementedError +class RoentgenHTML(RoentgenMoire, DefaultHTML): + """ + Simple HTML. + """ + + images = {} + + def osm(self, args: Arguments) -> str: + """OSM tag key or key–value pair of tag.""" + return osm(self, args) + + def color(self, args: Arguments) -> str: + """Simple color sample.""" + return ( + f'' + ) + + def icon(self, args: Arguments) -> str: + """Image with Röntgen icon.""" + size: str = self.clear(args[1]) if len(args) > 1 else 16 + return ( + f'' + ) + + def command(self, args: Arguments) -> str: + """ + Bash command from GitHub Actions configuration. + + See .github/workflows/test.yml + """ + return test_configuration.get_command(self.clear(args[0])) + + class RoentgenOSMWiki(RoentgenMoire, DefaultWiki): """ OpenStreetMap wiki.