mirror of
https://github.com/fooflington/selfdefined.git
synced 2025-08-01 10:29:06 +00:00
Style fixes (#144)
* change "title__thicc" classname to "title--thicc" to reflect BEM naming convention * fix indentation in index.njk * add vertical spacing between homepage sections * convert ".help" class to ".box__list" class CSS classes generally shouldn't be related to content * remove duplicate code for .page * change auto-grid class to "auto-fit", from "auto-fill" This reduces unused negative space on screens between 800-1200px wide * use proper BEM practice - block, then modifier class * refactor .flag styles to be more BEM * add BEM block-level class to h1 * refactor box__list to simply "list" * It will be its own component rather than element of the "box" block * Remove duplicate (older) thicc styles from _header.scss * rename .title--thicc to .thicc-headline to be more consistent with other "headline" heading classes * rename another .title--thicc -> .thicc-headline * refactor CSS selector from adjacent to class * refactor the whole header to separate grid layout and typography * remove unneeded grid style * it's not a grid item * remove sub-headline typography from _header.scss and add it to _typography.scss * remove horizontal margin from box below tablet size * noticed that the .box class, which is already squished on 320px wide screens, is more squished because of its margins. * allow headings to wrap if necessary noticed that headings (e.g. "development and build") were blowing out the grid on small screens and causing horizontal scroll * rename subtitle to "sub-headline" * convert <section> to <header> makes more semantic sense for a screen-reader, since this really is the header of the document. * discard heading wrapper element in favour of having just the heading element Co-authored-by: Oscar <ovlb@users.noreply.github.com>
This commit is contained in:
@@ -4,12 +4,12 @@
|
||||
definition.data.flag and
|
||||
definition.data.flag.text and
|
||||
(definition.data.flag.level == 'avoid') -%}
|
||||
<span class="flag__red">{{ definition.data.flag.text }}</span>
|
||||
<span class="flag flag--red">{{ definition.data.flag.text }}</span>
|
||||
{%- elseif
|
||||
definition.data.flag and
|
||||
definition.data.flag.text and
|
||||
(definition.data.flag.level == 'warning') -%}
|
||||
<span class="flag__yellow">{{ definition.data.flag.text }}</span>
|
||||
<span class="flag flag--yellow">{{ definition.data.flag.text }}</span>
|
||||
{% endif %}
|
||||
{%- if definition.data.sub_terms -%}
|
||||
<ul class="sub-terms" role="list" aria-label="{{definition.data.title}}">
|
||||
|
@@ -1,4 +1,4 @@
|
||||
<section>
|
||||
<section class="homepage-section homepage-section--toc">
|
||||
<h2 id="terms-heading" class="visually-hidden">Terms</h2>
|
||||
<nav class="" aria-labelledby="terms-heading">
|
||||
<ol class="multi-column u-no-padding-left list">
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<a href={{ parent.href }}>{{ parent.title }}</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
<h1 class="title__thicc" >{{ title }}</h1>
|
||||
<h1 class="thicc-headline" >{{ title }}</h1>
|
||||
{{ content | safe }}
|
||||
</main>
|
||||
{% endblock %}
|
||||
|
@@ -2,23 +2,25 @@
|
||||
layout: layouts/index.njk
|
||||
---
|
||||
|
||||
<section id="introduction" class="auto-grid">
|
||||
<h1 class="title__thicc" id="title">Self-Defined</h1>
|
||||
<p>A modern dictionary about us.<br>We define our words, but they don't define us.</p>
|
||||
<div>
|
||||
<p class="summary">
|
||||
Self-Defined seeks to provide more inclusive, holistic, and fluid definitions to reflect the diverse perspectives of the modern world.
|
||||
</p>
|
||||
<p>
|
||||
With the foundation of vocabulary, we can begin to understand lived experiences of people different than us. Words can provide us with a sense of identify and allow us to find kinship through common experiences.
|
||||
</p>
|
||||
</div>
|
||||
<div class="box">
|
||||
<h2 class="subtitle">Ways to help</h2>
|
||||
<ol class="help">
|
||||
<li>Submit words and definitions or contribute to our code base through <a href="https://github.com/tatianamac/selfdefined/pulls" rel="noreferral">pull requests</a> or <a href="https://github.com/tatianamac/selfdefined/issues" rel="noreferral">issues</a>. Start with our <a href="https://github.com/tatianamac/selfdefined/blob/master/CONTRIBUTING.md" rel="noreferral">contributing guidelines</a> and <a href="/documentation/">documentation</a>.</li>
|
||||
<li>Sponsor this work through <a href="https://opencollective.com/selfdefined">Open Collective</a> or <a href="https://github.com/sponsors/tatianamac">GitHub Sponsors</a>.</li>
|
||||
<li>Follow us on Twitter <a href="https://www.twitter.com/selfdefinedapp">@SelfDefinedApp</a>.</li>
|
||||
</ol>
|
||||
</div>
|
||||
</section>
|
||||
<header class="auto-grid introduction">
|
||||
<h1 class="introduction__title thicc-headline" id="title">
|
||||
Self-Defined
|
||||
</h1>
|
||||
<p class="introduction__body">A modern dictionary about us.<br>We define our words, but they don't define us.</p>
|
||||
<div>
|
||||
<p class="summary">
|
||||
Self-Defined seeks to provide more inclusive, holistic, and fluid definitions to reflect the diverse perspectives of the modern world.
|
||||
</p>
|
||||
<p>
|
||||
With the foundation of vocabulary, we can begin to understand lived experiences of people different than us. Words can provide us with a sense of identify and allow us to find kinship through common experiences.
|
||||
</p>
|
||||
</div>
|
||||
<div class="box">
|
||||
<h2 class="sub-headline">Ways to help</h2>
|
||||
<ol class="list">
|
||||
<li>Submit words and definitions or contribute to our code base through <a href="https://github.com/tatianamac/selfdefined/pulls" rel="noreferral">pull requests</a> or <a href="https://github.com/tatianamac/selfdefined/issues" rel="noreferral">issues</a>. Start with our <a href="https://github.com/tatianamac/selfdefined/blob/master/CONTRIBUTING.md" rel="noreferral">contributing guidelines</a> and <a href="/documentation/">documentation</a>.</li>
|
||||
<li>Sponsor this work through <a href="https://opencollective.com/selfdefined">Open Collective</a> or <a href="https://github.com/sponsors/tatianamac">GitHub Sponsors</a>.</li>
|
||||
<li>Follow us on Twitter <a href="https://www.twitter.com/selfdefinedapp">@SelfDefinedApp</a>.</li>
|
||||
</ol>
|
||||
</div>
|
||||
</header>
|
||||
|
Reference in New Issue
Block a user