kitbash Sign in Connect agent
Components

Statement

A large capitals statement on a field of faint dots with a small framed aside that can be dismissed, and a row of framed figures under it.

Part of the style

Night Chart Console

7 parts that belong together, with their tokens, type and rules.

Preview

Code
<style>
/* Goes after the pack's base.css */
:root {
  --night: #824e2d;
  --paper: #fbf6df;
  --paper-dim: rgba(251, 246, 223, 0.6);
  --paper-faint: rgba(251, 246, 223, 0.36);
  --night-dim: rgba(130, 78, 45, 0.6);
  --night-faint: rgba(130, 78, 45, 0.4);
  --smoke: #875d43;
  --fog: #f5f0d8;
  --wordmark-shade: #e5dec2;
  --map-ghost: #cbc3a1;
  --retro-face: #ded6b9;
  --retro-chip: #f4eed5;
  --retro-edge: #b6ac85;
  --scene-sky: #7d6905;
  --scene-sea: #7f6b07;
  --retro-bar: #7d6a0c;
  --retro-bar-end: #806e1a;
  --map-line: #8e791b;
  --scene-glow: #deb618;
  --map-live: #f9d971;
  --scene-lamp: #ffdb67;
  --scene-amber: #fed7a4;
}
</style>

<section class="statement">
  <svg class="statement__field" viewBox="0 0 1440 720" preserveAspectRatio="xMidYMid slice" aria-hidden="true" focusable="false">
    <path class="statement__dust" d="M159 551h.1M742 158h.1M23 192h.1M293 334h.1M230 283h.1M719 602h.1M1422 675h.1M49 184h.1M849 706h.1M929 63h.1M888 597h.1M896 220h.1M38 681h.1M942 485h.1M1252 216h.1M922 516h.1M86 674h.1M1344 279h.1M1191 49h.1M531 334h.1M442 347h.1M265 430h.1M1424 511h.1M1218 398h.1M1061 16h.1M1201 449h.1M1251 455h.1M1361 243h.1M1397 391h.1M175 70h.1M476 36h.1M957 383h.1M128 535h.1M842 506h.1M556 386h.1M516 320h.1M758 178h.1M472 418h.1M260 563h.1M26 242h.1M415 467h.1M1172 183h.1M944 634h.1M1119 185h.1M565 455h.1M1357 566h.1M1060 455h.1M645 160h.1M136 461h.1M1171 443h.1M1172 230h.1M1144 499h.1M265 699h.1M1240 123h.1M156 691h.1M663 232h.1M1102 630h.1M785 140h.1M1311 393h.1M1051 388h.1M651 692h.1M1082 618h.1M822 609h.1M1385 134h.1M1184 611h.1M729 514h.1M1262 35h.1M876 538h.1M992 55h.1M1069 518h.1M374 545h.1M719 670h.1M510 114h.1M538 341h.1M33 689h.1M381 131h.1M506 120h.1M990 346h.1M853 301h.1M559 16h.1M354 103h.1M1313 663h.1M1393 659h.1M1434 16h.1M233 502h.1M935 517h.1M754 504h.1M750 274h.1M1133 542h.1M292 242h.1M644 594h.1M678 681h.1M166 302h.1M491 31h.1M1254 272h.1M1073 222h.1M784 82h.1M194 490h.1M1003 508h.1M801 50h.1M1355 473h.1M1029 161h.1M801 66h.1M159 237h.1M19 174h.1M1066 614h.1M491 36h.1M982 193h.1M340 144h.1M1163 243h.1" />
    <path class="statement__dust statement__dust--bright" d="M335 461h.1M596 561h.1M6 485h.1M1232 656h.1M458 534h.1M744 264h.1M1060 694h.1M922 331h.1M39 409h.1M1159 85h.1M946 240h.1M1169 5h.1M648 569h.1M215 557h.1M655 239h.1M137 636h.1M1131 438h.1M462 373h.1M305 155h.1M106 9h.1M260 155h.1M1311 93h.1M190 586h.1M502 133h.1M1258 414h.1M664 522h.1M468 390h.1M615 573h.1M391 424h.1M1221 636h.1M130 532h.1M154 265h.1M163 492h.1M380 206h.1M766 631h.1M1062 246h.1M1404 609h.1M433 265h.1M796 231h.1M1045 274h.1M982 63h.1M109 469h.1M71 397h.1M63 219h.1" />
  </svg>
  <div class="statement__body">
    <p class="statement__lead">Small Hours is a radio station on a retired pilot boat, moored off Gull Reach and on air from dusk until the first ferry.</p>

    <aside class="statement__aside">
      <button class="statement__close" type="button" aria-label="Dismiss this note">
        <svg viewBox="0 0 10 10" aria-hidden="true" focusable="false"><path d="M1.5 1.5l7 7M8.5 1.5l-7 7" /></svg>
      </button>
      <p class="statement__note">Twelve volunteers, one mast and a kettle. Every night somebody takes the desk and plays what the daytime has no room for: slow records, field tapes, shipping news, long silences. Listeners with an aerial on the roof pass the signal along the coast.</p>
    </aside>
  </div>

  <dl class="statement__figures">
    <div class="statement__figure">
      <dt class="statement__term">Frequency</dt>
      <dd class="statement__value">87.9 MHz</dd>
    </div>
    <div class="statement__figure">
      <dt class="statement__term">On air</dt>
      <dd class="statement__value">Dusk to 05:40</dd>
    </div>
    <div class="statement__figure">
      <dt class="statement__term">Rooftop relays</dt>
      <dd class="statement__value">214</dd>
    </div>
    <div class="statement__figure">
      <dt class="statement__term">Nights in a row</dt>
      <dd class="statement__value">1,306</dd>
    </div>
  </dl>
</section>

<style>
  .statement {
    position: relative;
    padding: var(--section-space) var(--gutter);
    background: var(--night);
    color: var(--paper);
  }

  /* A field of dots behind the text. Each dot is a zero-length stroke with round ends, so it keeps its size at any width. */
  .statement__field {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
  }
  .statement__dust {
    fill: none;
    stroke: var(--paper-dim);
    stroke-linecap: round;
    stroke-width: 1.3;
    vector-effect: non-scaling-stroke;
  }
  .statement__dust--bright {
    stroke: var(--paper);
    stroke-width: 1.9;
  }

  .statement__body {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
    align-items: start;
    justify-content: space-between;
    gap: var(--space-xl) calc(100% / 12);
  }
  .statement__lead {
    margin: 0;
    font-size: var(--text-xl);
    letter-spacing: var(--tracking-tight);
    line-height: 1;
    text-transform: uppercase;
    text-wrap: balance;
  }

  .statement__aside {
    position: relative;
    padding: var(--space-m) var(--space-xl) var(--space-m) var(--space-m);
    border: var(--frame) solid var(--paper);
    background: var(--night);
    transition: opacity var(--time) ease, visibility 0s var(--time);
  }
  .statement__aside.is-dismissed {
    opacity: 0;
    visibility: hidden;
  }
  .statement__note {
    margin: 0;
    text-transform: uppercase;
  }
  .statement__close {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    display: grid;
    place-items: center;
    width: 1.375rem;
    height: 1.375rem;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    cursor: pointer;
  }
  .statement__close::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: var(--tap);
    height: var(--tap);
    translate: -50% -50%;
  }
  .statement__close svg {
    width: 0.625rem;
    height: 0.625rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.2;
  }
  .statement__close:focus-visible {
    outline: var(--frame) solid currentColor;
    outline-offset: 3px;
  }

  /* Framed boxes that share their edges. */
  .statement__figures {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: var(--section-space) 0 0;
    border: var(--frame) solid var(--paper);
    background: var(--night);
  }
  .statement__figure {
    display: grid;
    gap: var(--space-xs);
    padding: var(--space-m);
    text-transform: uppercase;
  }
  .statement__figure + .statement__figure {
    border-left: var(--frame) solid var(--paper);
  }
  .statement__term {
    color: var(--paper-dim);
    font-size: var(--text-xs);
    letter-spacing: var(--tracking-wide);
  }
  .statement__value {
    margin: 0;
    font-size: var(--text-l);
    letter-spacing: var(--tracking-tight);
    line-height: 1.15;
  }

  @media (max-width: 48rem) {
    .statement__body {
      grid-template-columns: minmax(0, 1fr);
    }
    .statement__aside.is-dismissed {
      display: none;
    }
    .statement__figures {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .statement__figure:nth-child(odd) {
      border-left: 0;
    }
    .statement__figure:nth-child(n + 3) {
      border-top: var(--frame) solid var(--paper);
    }
  }

  @media (prefers-reduced-motion: reduce) {
    .statement__aside {
      transition-duration: 0s;
    }
  }
</style>

<script>
  (() => {
    const DISMISSED = "is-dismissed";

    document.querySelectorAll(".statement").forEach((root) => {
      const aside = root.querySelector(".statement__aside");
      root.querySelector(".statement__close").addEventListener("click", () => aside.classList.add(DISMISSED));
    });
  })();
</script>

Similar components

Big statement

Big statement

Discipline shapes

Discipline shapes

Reading passage

Reading passage

Project chapter

Project chapter

Echo title card

Echo title card

Case study flood

Case study flood

Essay

Essay

Black statement

Black statement