Fossil User Forum

Bullets in /dir type=tree View in Default Skin
Login

Bullets in /dir type=tree View in Default Skin

Bullets in /dir type=tree View in Default Skin

(1) By DB (ABC...) on 2024-07-27 04:41:59 [link] [source]

With the most recent fossil release, 2.24, the default skin started showing bullets for the <ul> and <li> in the /dir?ci=tip&type=tree path.

At first I thought it was a design choice, to space things out, but quickly decided it was a side-effect due to a CSS change.

I was able to “fix” it, but dealing with CSS in fossil is not like what I’m used to, so I kept my mouth shut and waited for someone else to say something or submit a patch.

It doesn’t look like anyone’s said anything.

These lines are part of the answer. I can turn this off in the browser’s dev web inspector, then the file’s tree view becomes normal again.

But this has ramifications for the content class, regular unordered lists, and list items. I didn’t explore to see what would be effected. I didn’t explore creating a custom class for the /dir page. And I only checked in two browsers.

I’m hoping someone else can deal with this. :-) In the mean time I’ve found I like the “Original” skin. :-)

Thank you.

(2) By Stephan Beal (stephan) on 2024-07-27 10:32:23 in reply to 1 [link] [source]

These lines are part of the answer.

That's now fixed on trunk with:

-.content ul li {
+.content ul:not(.browser) li {

Thank you for the report.

(3) By DB (ABC...) on 2024-07-28 20:49:54 in reply to 2 [link] [source]

Gladly.

I’m a fan of the tree view. :-)

The <ul> on the /dir?ci=tip&type=tree page doesn't have any classes; forcibly adding the browser class using the web browser's very handy web inspector didn't remove the bullets. There's a filetree class in its <div> wrapper, however.

<div class=​"filetree">​
    <ul>​ 

So I ended up turning them off at the list item level.

Index: skins/default/css.txt
==================================================================
--- skins/default/css.txt
+++ skins/default/css.txt
@@ -355,11 +355,11 @@
 .content pre, table.numbered-lines > tbody > tr {
   hyphens: none;
   line-height: 1.25;
 }
 
-.content ul:not(.browser) li {
+.content ul:not(.browser) li:not(.dir,.file) {
   list-style-type: disc;
 }
 
 .artifact > .content table,
 .dir      > .content table,

Not widely tested.

(4.1) By Stephan Beal (stephan) on 2024-07-28 22:03:33 edited from 4.0 in reply to 3 [source]

The <ul> on the /dir?ci=tip&type=tree page doesn't have any classes;

It does in the trunk. Perhaps you're using an old version? On the /dir page, the element which contains the list looks like:

<div class="columns files" style="columns: 21ex auto">
<ul class="browser">
<li class="file">...

noting that the 21ex part is calculated when the page is generated.

Edit: i see now that you're using 2.24, but cannot explain the lack of the browser class in that version, as that class has been around since 2018:

$ fossil annotate browse.c | grep 'ul class'
9131af26f1 2018-08-20   366:   @ <ul class="browser">

(5) By Stephan Beal (stephan) on 2024-07-28 22:21:58 in reply to 3 [link] [source]

The <ul> on the /dir?ci=tip&type=tree page doesn't have any classes; ... There's a filetree class in its <div> wrapper, however.

Found it - it's not the /dir page, but the /tree page. The discs are now (in trunk) removed from the default skin on that page.

(6) By DB (ABC...) on 2024-07-29 00:54:16 in reply to 5 [link] [source]

On the /test-all-help page I see there's a difference between what /dir can do and what /tree can. But there's overlap.

Here's how I came to end up in the /dir path.

When I click the Main Menu link, "/sitemap" the second list item is File Browser and the next two links after it, as well go to the /tree path. Tree-view, Trunk Check-in, and Flat-view.

After choosing File Browser, all four of the submenu links go to the /dir path.

After choosing Tree-view, Trunk Check-in both All and Flat-view follow the /tree path.

After choosing Flat-view, all four of the submenu links go to the /dir path.

Today's browsers and long paths make it difficult to see the full URL. I didn't notice the difference between /dir and /tree in the URL, let alone the parameters. :-(

Since I prefer the tree view to the flat view I customize the main menu and used the link I happened to copy from the address bar at the time. I guess there was a 2/3rds chance I'd do what I did. I must have copied the URL from the menu bar after choosing File Browser > Tree View from the submenu.

I've not yet built your update, but it looks logical.