SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit 9dcfebb1 authored by George Katsikas's avatar George Katsikas :goat:
Browse files

fix summary triangle overriden by flexbox

parent e591289c
No related branches found
No related tags found
1 merge request!52New Production page fixes and oversights
<details id="productionstream-{{ productionstream.id }}-details"
class="border border-2 mx-3 p-2 bg-primary bg-opacity-10">
<summary class="summary-unstyled p-2">
<summary class="list-none">
{% include "production/_productionstream_details_summary_contents.html" with productionstream=productionstream %}
</summary>
......
......@@ -25,9 +25,9 @@
</div>
<details id="productionstreams-filter-details" class="card my-4">
<summary class="card-header fs-6 d-inline-flex align-items-center">
Search / Filter / Bulk Actions
<div class="d-none d-sm-inline-flex ms-auto align-items-center">
<summary class="card-header fs-6 d-flex flex-row align-items-center justify-content-between list-triangle">
<div>Search / Filter / Bulk Actions</div>
<div class="d-none d-md-flex align-items-center">
<div id="indicator-search-productionstreams" class="htmx-indicator">
<button class="btn btn-warning text-white d-none d-md-block me-2"
......
......@@ -202,15 +202,6 @@ $theme-colors: (
$theme-colors-rgb: map-loop($theme-colors, to-rgb, "$value");
// Browser specific fixes
// Select summary in details with list-style: none and remove triangle for safari
.summary-unstyled {
list-style: none;
&::-webkit-details-marker {
display: none;
}
}
// Utilities for common display issues
// Hide div
.d-none-empty:empty {
......@@ -220,4 +211,36 @@ $theme-colors-rgb: map-loop($theme-colors, to-rgb, "$value");
.checkbox-lg {
width: 1.5em !important;
height: 1.5em !important;
}
summary {
// Remove triangle for webkit browsers causing problems with flexbox
&::-webkit-details-marker {
display: none;
}
// Remove all list styles
&.list-none {
list-style: none;
}
// List triangle for summary element (necessary with display: flex)
&.list-triangle {
position: relative;
padding-left: 2em !important;
// Styling the equilateral triangle
&::before {
content: "▶";
position: absolute;
left: 0.75em;
top: 50%;
transform: translateY(-50%);
}
}
}
// Rotate the equilateral triangle when summary is open
details[open] summary.list-triangle::before {
content: "▼";
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment