From 6f112fd1e6abae643a886f0e7e93406303010ce9 Mon Sep 17 00:00:00 2001 From: Fred Hohman Date: Fri, 14 Aug 2020 00:06:37 -0400 Subject: [PATCH] break table title and hide tags column on mobile #13 --- src/diagrams/example-table.svelte | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/diagrams/example-table.svelte b/src/diagrams/example-table.svelte index c6de69d..cb4c4ee 100644 --- a/src/diagrams/example-table.svelte +++ b/src/diagrams/example-table.svelte @@ -128,11 +128,18 @@ color: var(--orange); } */ + .break { display: none; } + .hide-column { display: auto; } + @media(max-width: 1000px) { td, tr { font-size: 0.85em !important; line-height: 1.35em; } + + .break { display: inline-block; } + .hide-column { display: none; } + } @@ -142,8 +149,8 @@ {lastSortKey = sortKey; sortKey = "title"; sort()}}>Title {sortKey === "title" ? sortIcon : ""} - {lastSortKey = sortKey; sortKey = "journal"; sort()}}>Publication (or author) {sortKey === "journal" ? sortIcon : ""} - {lastSortKey = sortKey; sortKey = "tags"; sort()}}>Tags {sortKey === "tags" ? sortIcon : ""} + {lastSortKey = sortKey; sortKey = "journal"; sort()}}>Publication
or Author {sortKey === "journal" ? sortIcon : ""} + {lastSortKey = sortKey; sortKey = "tags"; sort()}}>Tags {sortKey === "tags" ? sortIcon : ""} {lastSortKey = sortKey; sortKey = "year"; sort()}}>Year {sortKey === "year" ? sortIcon : ""} @@ -156,7 +163,7 @@ {example.entryTags.journal !== "Self published" ? example.entryTags.journal : example.entryTags.author} - {example.entryTags.tags} + {example.entryTags.tags} {example.entryTags.year} {/each}