second draft site creator and adjustments
This commit is contained in:
parent
5b61869329
commit
9ecadc87d7
|
|
@ -11,6 +11,24 @@ shortcuts:
|
|||
tab_color: 'tab_colour_imported'
|
||||
custom_permutation: 'custom_permutated'
|
||||
|
||||
start: |
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport"
|
||||
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.0-beta1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-0evHe/X+R7YkIZDRvuzKMRqM+OrBnVFBL6DOitfPri4tjfHxaWutUpFmBp4vmVor" crossorigin="anonymous">
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.0-beta1/dist/js/bootstrap.bundle.min.js" integrity="sha384-pprn3073KE6tl6bjs2QrFaJGz5/SUsLqktiwsUTF55Jfv3qYSDhgCecCxMW52nD2" crossorigin="anonymous"></script>
|
||||
<title>{}</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
end:
|
||||
'</body>
|
||||
</html>'
|
||||
|
||||
images:
|
||||
logo: 'resources/images/logo.png'
|
||||
favicon: 'resources/images/favicon.png'
|
||||
|
|
|
|||
|
|
@ -0,0 +1,40 @@
|
|||
@[start]['doc']
|
||||
|
||||
@{sch}[ht]
|
||||
@{vuln}[1]
|
||||
@{vuln}[1,2]
|
||||
|
||||
@{custom_pict}{class="watabuya"}[number=2, _important=22]
|
||||
|
||||
@[custom_permutation]
|
||||
|
||||
@[custom_permutation]{class="bouyou"}[number=44]
|
||||
|
||||
|
||||
Oneline import @[tab_bnw]{class="sojek"} with three imports @[tab_color] @{image}{class="sojek dark" color="red"}[number=2]
|
||||
|
||||
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
|
||||
|
||||
|
||||
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]
|
||||
|
|
@ -1,63 +1,49 @@
|
|||
### header 3 ###
|
||||
[link]("http://test.icule"){style="underline: None;"}
|
||||
@[start]['bootstrap']
|
||||
|
||||
Structural Elements:
|
||||
<<div
|
||||
This is a div
|
||||
div>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
|
||||
<<article
|
||||
|
||||
*italic*
|
||||
**bold**
|
||||
#. Lists
|
||||
|
||||
# Header # {style='height=44px'}
|
||||
## Header 2 ##
|
||||
|
||||
This is an article
|
||||
article>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
|
||||
<<aside
|
||||
oneline
|
||||
aside>> {class="bubuyo"}
|
||||
~~ element
|
||||
multiple
|
||||
lines
|
||||
element~~ {class="bubuyo"}
|
||||
|
||||
article>>
|
||||
|
||||
~~header
|
||||
|
||||
header~~
|
||||
This is an aside
|
||||
aside>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
|
||||
<<section
|
||||
This is a section
|
||||
section>>[class='blue', 123]{var='test', number=11}{{cinsertion}}
|
||||
<<div
|
||||
<<article
|
||||
<<aside
|
||||
<<section
|
||||
Text
|
||||
section>>[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]
|
||||
|
|
@ -1 +0,0 @@
|
|||
::< whatever.bpr > < whatever2.bpr > (import file whatever.bpr)
|
||||
|
|
@ -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 "<br/>\n"
|
||||
def export(self, _): # TODO: add lookahead for double linebreak to force break
|
||||
return "\n"
|
||||
|
||||
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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())
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue