File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 206206 plugin outranks this theme in CKAN's template search path, so it cannot be
207207 removed via a template override from here; hide it with CSS instead. The
208208 dictionary renders as a .module-content whose direct children include the
209- per-field .accordion elements (built by datastore/snippets/dictionary_view.html);
210- the only other .accordion in the app (the admin data-type page) is not wrapped
211- in a .module-content, so the "> .accordion" child combinator targets the data
212- dictionary alone. The dictionary remains editable on the dedicated /dictionary
213- page. */
214- .module-content : has (> .accordion ) {
209+ per-field .accordion elements (built by datastore/snippets/dictionary_view.html).
210+ Scope this tightly: the admin trash page (admin/snippets/data_type.html) also
211+ renders .accordion elements as direct children of a .module-content -- the one
212+ core page.html wraps around {% block primary_content_inner %} -- so a bare
213+ ".module-content:has(> .accordion)" blanks the whole trash page, Purge all form
214+ included. Two things distinguish the dictionary: its .module-content is a direct
215+ child of a <section class="module"> (the trash one sits in page.html's
216+ <article class="module">), and it opens with an <h2>Data Dictionary</h2> heading
217+ immediately before the accordions (the trash one opens with a <form>). Require
218+ both. The dictionary remains editable on the dedicated /dictionary page, which
219+ nests .accordion-item inside a <form> and never matched this rule. */
220+ section .module > .module-content : has (> h2 + .accordion ) {
215221 display : none;
216222}
217223
You can’t perform that action at this time.
0 commit comments