-
Notifications
You must be signed in to change notification settings - Fork 133
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
Fix minor UI issues with default.md #2278
Conversation
@lhw-1 need resolve conflict |
8f11bd2
to
3d9d5ae
Compare
Here is a summary of the changes made targeting "Remove generation of blank lines after the navbar in In the current version of MarkBind, when the user calls ...
</nav>
</div>
<footer>
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {{MarkBind}}]</small>
</div>
</footer> The issue brought up in #1866 is that there are unnecessary blank lines here that are generated during our ...
</nav>
</div>
{% set defaultFooter %}
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {% raw %}{{MarkBind}}{% endraw %}]</small>
</div>
{% endset %}
<footer>
{{ footer or defaultFooter }}
</footer> In the case where the ...
</nav>
</div>
<footer>
{% set defaultFooter %}
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {% raw %}{{MarkBind}}{% endraw %}]</small>
</div>
{% endset %}
{{ footer or defaultFooter }}
</footer> And this will result in the following ...
</nav>
</div>
<footer>
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {{MarkBind}}]</small>
</div>
</footer> The blank lines between the navbar and the footer are now reduced to a single blank line (which is acceptable), but there are now new unnecessary blank lines introduced within the ...
</nav>
</div>
<footer>
{%- set defaultFooter %}
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {% raw %}{{MarkBind}}{% endraw %}]</small>
</div>
{% endset -%}
{{ footer or defaultFooter }}
</footer> And the resulting ...
</nav>
</div>
<footer>
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {{MarkBind}}]</small>
</div>
</footer> Since there is still one newline within the ...
</nav>
</div>
<footer>
{%- set defaultFooter -%}
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {% raw %}{{MarkBind}}{% endraw %}]</small>
</div>
{%- endset -%}
{{ footer or defaultFooter }}
</footer> And the resulting ...
</nav>
</div>
<footer>
<!-- Support MarkBind by including a link to us on your landing page! -->
<div class="text-center">
<small>[Generated by {{MarkBind}}]</small>
</div>
</footer> This is the behavior we would like to see, without unnecessary blank lines. Unfortunately, because we remove the inner blank lines, this will affect custom footers that users may use. When I updated our functional tests, the
To:
In order to keep the behavior of custom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@lhw-1 possible to update the outdated content in here? https://markbind-master.netlify.app/devguide/bootcamp/exploremarkbind#modify-site-structure-and-configuration Should have done so in your previous PR updating the template. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you have another look at packages/core/src/Site/siteConvertLayout.njk to ensure it's up-to-date?
Thanks for the catch! There does seem to be inconsistencies between On another note, I wonder if we can work on a further refactor to have |
Good suggestion and yes can explore. I wonder if there will be a case where the two (default and convert) will deviate further in the future. From the perspective of the functionality, I think it feels more natural to have "default.md" dictate "siteConvertLayout.njk" |
What is the purpose of this pull request?
Overview of changes:
Addresses two of the issues related to
_markbind/default.md
brought up in #1866.Specific improvements:
default.md
default.md
Anything you'd like to highlight/discuss:
Testing instructions:
Try
markbind init
ormarkbind init --convert
on a pre-existing set of documents, and ensure that changes are reflected.Proposed commit message: (wrap lines at 72 characters)
Fix minor UI issues with default.md
Checklist: ☑️