diff --git a/frontend/src/assets/main.css b/frontend/src/assets/main.css index 2301f1e..8080aa6 100644 --- a/frontend/src/assets/main.css +++ b/frontend/src/assets/main.css @@ -37,12 +37,6 @@ :root { --root-font-size: calc(8px + 8 * 100vw / 1000); } - header .buttons:has(input[type='search']) > div { - display: none; - } - header .buttons > div:has(input[type='search']) { - display: inherit; - } } @media screen and (min-width: 2000px) { :root { @@ -78,17 +72,13 @@ } header { display: flex; - flex-direction: row-reverse; justify-content: space-between; - align-items: end; } - header .breadcrumb { - flex-shrink: 1; - } - header .breadcrumb > * { - flex-shrink: 1; - padding-top: 1rem !important; - padding-bottom: 1rem !important; + header .headermain { order: 1; } + header .breadcrumb { align-self: stretch; } + header .action-button { + width: 2em; + height: 2em; } } @media print { @@ -142,6 +132,9 @@ left: 0; } } +* { + box-sizing: border-box; +} html { font-size: var(--root-font-size); overflow: hidden; diff --git a/frontend/src/components/BreadCrumb.vue b/frontend/src/components/BreadCrumb.vue index 5de7e9c..032c9b6 100644 --- a/frontend/src/components/BreadCrumb.vue +++ b/frontend/src/components/BreadCrumb.vue @@ -12,6 +12,8 @@ :ref="el => setLinkRef(0, el)" :class="{ current: !!isCurrent(0) }" :aria-current="isCurrent(0)" + @click.prevent="navigate(0)" + title="/" > @@ -21,6 +23,7 @@ :aria-current="isCurrent(index + 1)" @click.prevent="navigate(index + 1)" :ref="el => setLinkRef(index + 1, el)" + :title="`/${longest.slice(0, index + 1).join('/')}`" >{{ location }} @@ -101,27 +104,31 @@ watchEffect(() => { --breadcrumb-transtime: 0.3s; } .breadcrumb { + flex: 1 1 auto; display: flex; - list-style: none; + min-width: 20%; + max-width: 100%; + min-height: 2em; margin: 0; padding: 0 1em 0 0; } .breadcrumb > a { + display: flex; + align-items: center; margin: 0 -0.5em 0 -0.5em; padding: 0; max-width: 8em; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; - height: 1.5em; color: var(--breadcrumb-color); padding: 0.3em 1.5em; clip-path: polygon(0 0, 1em 50%, 0 100%, 100% 100%, 100% 0, 0 0); transition: all var(--breadcrumb-transtime); } .breadcrumb a:first-child { - margin-left: 0; - padding-left: .2em; + padding-left: 1.5em; + padding-right: 1.7em; clip-path: none; } .breadcrumb a:last-child { @@ -148,9 +155,9 @@ watchEffect(() => { } .breadcrumb svg { /* FIXME: Custom positioning to align it well; needs proper solution */ - padding-left: 0.8em; width: 1.3em; height: 1.3em; + margin: -.5em; fill: var(--breadcrumb-color); transition: fill var(--breadcrumb-transtime); } diff --git a/frontend/src/components/HeaderMain.vue b/frontend/src/components/HeaderMain.vue index 5fab906..251b30f 100644 --- a/frontend/src/components/HeaderMain.vue +++ b/frontend/src/components/HeaderMain.vue @@ -1,31 +1,29 @@ @@ -93,24 +91,18 @@ defineExpose({ -@/stores/main