Skip to content

Make API reference constant section compact, renamings #132

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

Merged
merged 1 commit into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions _includes/api.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ <h1>{{ ref.info.brief }}</h1>
{%- if functions.size > 0 -%}
<table class="compact">
<tr>
<th>FUNCTION</th>
<th>FUNCTIONS</th>
<th></th>
</tr>
{%- for function in functions -%}
Expand All @@ -27,7 +27,7 @@ <h1>{{ ref.info.brief }}</h1>
{%- if variables.size > 0 -%}
<table class="compact">
<tr>
<th>CONSTANT</th>
<th>CONSTANTS</th>
<th></th>
</tr>
{%- for variable in variables -%}
Expand Down Expand Up @@ -57,7 +57,7 @@ <h1>{{ ref.info.brief }}</h1>
{%- if messages.size > 0 -%}
<table class="compact">
<tr>
<th>MESSAGE</th>
<th>MESSAGES</th>
<th></th>
</tr>
{%- for message in messages -%}
Expand Down Expand Up @@ -142,14 +142,14 @@ <h4>{{ function.name }}()<a href="#{% include ref_anchorlink.html element=functi
<h2>Constants</h2>
{%- for variable in variables -%}
{% include ref_anchor_target.html element=variable %}
<h4>{{ variable.name }}<a href="#{% include ref_anchorlink.html element=variable %}" class="anchor-link"/></a></h4>
<p>{{ variable.description }}</p>
<h5 class="compact">{{ variable.name }}<a href="#{% include ref_anchorlink.html element=variable %}" class="anchor-link"/></a></h5 class="compact">
<p class="compact">{{ variable.description }}</p>

{%- if variable.parameters.size > 0 -%}
{% include api_parameters.html parameters=variable.parameters %}
{%- endif -%}

<hr/>
{% if forloop.last == false %}<hr class="compact"/>{% else %}<hr/>{% endif %}
{%- endfor -%}
{%- endif -%}

Expand Down
13 changes: 13 additions & 0 deletions _scss/defold.scss
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,19 @@ mark {
margin-block-end: 0;
}

hr.compact {
margin-top: 1rem;
margin-bottom: 1.5rem;
}

h5.compact {
margin-bottom: 5px;
}

p.compact {
margin-bottom: 1.5rem;
}

/*******************************************************************************
* Page setup (to keep footer always at the bottom)
* Used in _layouts/base.html
Expand Down