Changeset 6c574b4 in Klonkt


Ignore:
Timestamp:
06/20/2026 06:56:39 AM (3 months ago)
Author:
roboburr <roboburr@…>
Branches:
main
Children:
374fbe9
Parents:
d252ce8
Message:

fix(epk): clear custom checkbox instead of unclear native one

Native checkbox rendered poorly in dark mode. Now a custom box: empty with
a border, and an accent box with a white ✓ when checked (+ row tint). Native
input hidden but functional.

Co-Authored-By: Claude <noreply@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/views/pages/admin-epk.ejs

    rd252ce8 r6c574b4  
    3636              <label class="epk-pick-item">
    3737                <input type="checkbox" name="epk_tracks" value="<%= t.id %>" <%= chosenTracks.indexOf(t.id) >= 0 ? 'checked' : '' %>>
     38                <span class="epk-box" aria-hidden="true">✓</span>
    3839                <span class="epk-pick-title"><%= t.title || '(zonder titel)' %></span>
    3940                <% if (t.artist) { %><span class="epk-pick-artist"><%= t.artist %></span><% } %>
     
    7273  .admin-page .epk-pick-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.6rem; border-radius: 6px; cursor: pointer; border: 1px solid transparent; }
    7374  .admin-page .epk-pick-item:hover { background: var(--paper); }
    74   .admin-page .epk-pick-item input { width: 18px; height: 18px; flex: 0 0 auto; accent-color: var(--accent); cursor: pointer; }
    75   /* Duidelijk aangevinkt: accent-tint + rand + balkje links. */
     75  /* Native checkbox verbergen; we tekenen een eigen, duidelijk vakje (.epk-box). */
     76  .admin-page .epk-pick-item input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
     77  .admin-page .epk-box {
     78    flex: 0 0 auto; width: 20px; height: 20px;
     79    border: 2px solid var(--rule); border-radius: 5px;
     80    display: grid; place-items: center;
     81    color: transparent; font-size: 13px; font-weight: 900; line-height: 1;
     82  }
     83  .admin-page .epk-pick-item:has(input:checked) .epk-box { background: var(--accent); border-color: var(--accent); color: #fff; }
     84  /* Aangevinkte rij ook getint. */
    7685  .admin-page .epk-pick-item:has(input:checked) {
    77     background: color-mix(in srgb, var(--accent) 16%, transparent);
     86    background: color-mix(in srgb, var(--accent) 14%, transparent);
    7887    border-color: color-mix(in srgb, var(--accent) 45%, transparent);
    79     box-shadow: inset 3px 0 0 var(--accent);
    8088  }
    81   .admin-page .epk-pick-item input:disabled { opacity: .4; }
     89  .admin-page .epk-pick-item:has(input:disabled) { opacity: .45; cursor: not-allowed; }
    8290  .admin-page .epk-pick-title { font-weight: 600; }
    8391  .admin-page .epk-pick-artist { color: var(--ink-muted, var(--ink-soft)); font-size: 0.85rem; }
Note: See TracChangeset for help on using the changeset viewer.