Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTML transform does not handle conditional variables #189

Closed
jeromesimeon opened this issue Mar 4, 2020 · 1 comment
Closed

HTML transform does not handle conditional variables #189

jeromesimeon opened this issue Mar 4, 2020 · 1 comment
Assignees

Comments

@jeromesimeon
Copy link
Member

jeromesimeon commented Mar 4, 2020

Describe the bug
Calling the transform with the --html flag on markdown with conditional variables raises and error.

To Reproduce

bash-3.2$ cat test/data/latedelivery.md 
cat test/data/latedelivery.md 
# HELLO! This is the contract editor. 

And below is a **clause**.

``` <clause src="https://templates.accordproject.org/archives/[email protected]" clauseid="87721b95-7e43-4441-82c7-b4d4db207e6f">
Late Delivery and Penalty.
----

In case of delayed delivery<if id="forceMajeure" value="%20except%20for%20Force%20Majeure%20cases%2C" whenTrue="%20except%20for%20Force%20Majeure%20cases%2C" whenFalse=""/>
<variable id="seller" value="%22Dan%22"/> (the Seller) shall pay to <variable id="buyer" value="%22Steve%22"/> (the Buyer) for every <variable id="penaltyDuration" value="2%20days"/>
of delay penalty amounting to <variable id="penaltyPercentage" value="10.5"/>% of the total value of the Equipment
whose delivery has been delayed. Any fractional part of a <variable id="fractionalPart" value="days"/> is to be
considered a full <variable id="fractionalPart" value="days"/>. The total amount of penalty shall not however,
exceed <variable id="capPercentage" value="55.0"/>% of the total value of the Equipment involved in late delivery.
If the delay is more than <variable id="termination" value="15%20days"/>, the Buyer is entitled to terminate this Contract.
bash-3.2$ ../markdown-cli/index.js parse --sample test/data/latedelivery.md --html 
6:28:43 PM - error: Unhandled type ConditionalVariable
@jeromesimeon
Copy link
Member Author

This is fixed in #190
Separate issue on softbreaks roundtripping filed as #191

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant