>[class='blue', 123]{var='test', number=11}{{cinsertion}}
+<>[class='blue', 123]{var='test', number=11}{{cinsertion}}
+aside>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
+article>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
+div>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
+# Header 1 #[class='blue', 123]{var='test', number=11}{{cinsertion}}
+! Display 1 ![class='blue', 123]{var='test', number=11}{{cinsertion}}
-@{custom_pict}
-@{sch}[ht]
-@{vuln}[1]
-@{vuln}[1,2]
-
-@{custom_pict}{class="watabuya"}[number=2, _important=22]
-
-@[custom_permutation]
-
-@[custom_permutation]{class="bouyou"}[number=44]
+Inline Element:
+[Link text]('http://this.is.a.link')
+*This is in italic*
+**This is strong**
+~~This is stricken through~~
+__This is underlined__
+(#1)This is a custom span(#1)
-Oneline import @[tab_bnw]{class="sojek"} with three imports @[tab_color] @{image}{class="sojek dark" color="red"}[number=2]
+Oneline elements:
+- This is an unordered list item
+- This is an unordered list item
+- This is an unordered list item[class='blue', 123]{var='test', number=11}{{cinsertion}}
+#. This is an ordered list item
+#. This is an ordered list item
+#. This is an ordered list item[class='blue', 123]{var='test', number=11}{{cinsertion}}
-add {{class}} at the end of an element for instant bootstrapyfication (class="") (class_insert)
-add {html} at the end of an element to add something to your html markup element (style='border-top: 2px') (html_insert)
-add [statement/str/float] at the end of an element to add something that must be interpreted by the parser
- add [int] to modify the path for aliases and images (vuln[1] looks for vuln1.png), you can add multiple with commas for multiple images variations
+This is a long text segment. This is a long text segment. This is a long text segment. This is a long text segment. This is a long text segment. This is a long text segment. This is a long text segment. This is a long text segment.
+I wish there could be linebreaks.
-
-filler
-::< whatever.bpr > < whatever2.bpr > (import file whatever.bpr)
-filler2
-
-.vky
-=> base.vky / .bky
-
-
-
--------------------
-shortcuts.yaml
- permutations
- images/icons
- glossaire
-
-navbar.yaml
-config.yaml
+@[end]
\ No newline at end of file
diff --git a/example_userfiles/index2.bpr b/example_userfiles/index2.bpr
deleted file mode 100644
index 099cca6..0000000
--- a/example_userfiles/index2.bpr
+++ /dev/null
@@ -1 +0,0 @@
-::< whatever.bpr > < whatever2.bpr > (import file whatever.bpr)
diff --git a/src/bootstraparse/modules/context_mngr.py b/src/bootstraparse/modules/context_mngr.py
index 5deb5d4..4cdd97a 100644
--- a/src/bootstraparse/modules/context_mngr.py
+++ b/src/bootstraparse/modules/context_mngr.py
@@ -269,6 +269,9 @@ class DisplayContainer(BaseContainer):
self.others["display_level"] = len(self.content[0].content[0])
return super().export(exm)
+ def get_content(self, exm, arbitrary_list=None):
+ return self.content[0].content[1]
+
class TableSeparatorContainer(BaseContainer):
pass
@@ -305,8 +308,8 @@ class TableCellContainer(BaseContainer):
class LinebreakContainer(BaseContainer):
- def export(self, _): # MONITOR: Observe behaviour when we'll be done, might cause unintended side effects
- return "
\n"
+ def export(self, _): # TODO: add lookahead for double linebreak to force break
+ return "\n"
"""
diff --git a/src/bootstraparse/modules/sitecrawler.py b/src/bootstraparse/modules/sitecrawler.py
index 98ba1e1..a061028 100644
--- a/src/bootstraparse/modules/sitecrawler.py
+++ b/src/bootstraparse/modules/sitecrawler.py
@@ -56,7 +56,7 @@ class SiteCrawler:
preparser_path = os.path.join(self.initial_path, root, file)
pp = preparser.PreParser(preparser_path, self._env, dict_of_imports=self.global_dict_of_imports)
pp.do_imports()
- p = self.create_file(os.path.join(self.destination_path, root, file))
+ p = self.create_file(os.path.join(self.destination_path, root, os.path.splitext(file)[0] + ".html"))
self.preparsers.append((pp, p))
return self.preparsers
diff --git a/src/bootstraparse/modules/sitecreator.py b/src/bootstraparse/modules/sitecreator.py
index 37995af..38d90a4 100644
--- a/src/bootstraparse/modules/sitecreator.py
+++ b/src/bootstraparse/modules/sitecreator.py
@@ -52,7 +52,6 @@ def preparse_parse(preparser):
def save(list_of_containers, destination, env):
- rich.print(list_of_containers[0])
with open(destination, "w") as output_file:
output_file.write(export.ContextConverter(list_of_containers, env.export_mngr).process_pile().read())