wiki icon indicating copy to clipboard operation
wiki copied to clipboard

feat: New tree navigation

Open myml opened this issue 2 years ago • 21 comments

use treeview replace v-list component.

image

Online https://wiki.deepin.org/zh/home

myml avatar May 27 '22 10:05 myml

Nice commit, I love it

tevenfeng avatar Jun 05 '22 12:06 tevenfeng

OMG YES!!!!!

davidflypei avatar Jun 07 '22 15:06 davidflypei

Nice

Pandaft avatar Jun 08 '22 05:06 Pandaft

it's so great!

it's one good idea to put the toc bar to the right.

图片

is it included in this PR?

zhuzhzh avatar Jun 08 '22 14:06 zhuzhzh

it's so great!

it's one good idea to put the toc bar to the right.

图片

is it included in this PR?

No, I did it with css override. You can copy the code to "Admin Area -> Theme -> Code injection -> css override"

.page-col-sd {
  order: 2;
  width: 240px
}
.page-col-content {
  order: 1
}
@media (min-width: 1264px) {
  .v-application--is-ltr .offset-lg-3 {
    margin-left: 0!important
  }
}

myml avatar Jun 09 '22 01:06 myml

it's so great! it's one good idea to put the toc bar to the right. 图片 is it included in this PR?

No, I did it with css override. You can copy the code to "Admin Area -> Theme -> Code injection -> css override"

.page-col-sd {
  order: 2;
  width: 240px
}
.page-col-content {
  order: 1
}
@media (min-width: 1264px) {
  .v-application--is-ltr .offset-lg-3 {
    margin-left: 0!important
  }
}

thanks very much!

one questions about this tree navi: if the level is deep or the title is long, does the left navigation show the horizontal scroll bar?

zhuzhzh avatar Jun 09 '22 03:06 zhuzhzh

Not ready yet!

myml avatar Jun 09 '22 13:06 myml

Not ready yet!

What's left to do?

davidflypei avatar Jun 09 '22 16:06 davidflypei

No, it won't. Same as the old.

myml avatar Jun 10 '22 02:06 myml

Not ready yet!

What's left to do?

I am not sure if people like it. This commit contains three types navigation(Static, Site Tree and new Site Tree). Maybe we should just keep a site tree?

I have a longer-term plan. Static Navigation also use treeview components and support multiple levels.

myml avatar Jun 10 '22 02:06 myml

Not ready yet!

What's left to do?

I am not sure if people like it. This commit contains three types navigation(Static, Site Tree and new Site Tree). Maybe we should just keep a site tree?

I have a longer-term plan. Static Navigation also use treeview components and support multiple levels.

I definitely like it. It's great that the long-term goal is Static multi-levels. Because that is greatly needed. did you say static is already included in this commit or that's something you are still working on?

davidflypei avatar Jun 14 '22 13:06 davidflypei

I just pulled it. I see now what you mean. I think we should make it an option on the admin page. Makes more sense that way. Then get it in a release and then work towards the static multi-level. There's more to change with that and getting this tree view may tie a lot of people over till static multi-level can be implemented.

davidflypei avatar Jun 14 '22 15:06 davidflypei

I just pulled it. I see now what you mean. I think we should make it an option on the admin page. Makes more sense that way. Then get it in a release and then work towards the static multi-level. There's more to change with that and getting this tree view may tie a lot of people over till static multi-level can be implemented.

I finished!

myml avatar Jun 23 '22 14:06 myml

Sweet! I can't wait till this can be implemented!

davidflypei avatar Jun 29 '22 12:06 davidflypei

@NGPixel Do you have any timeline on this being implemented?

davidflypei avatar Jul 20 '22 14:07 davidflypei

Could the tree navigation be folded?

I hope the page-col-sd elements be folded or removed as well. So that more space is used to display the page-col-content .

I use the following code to close page-col-sd, but page-col-content doesn't use the space of page-col-sd occupied originally.

.page-col-sd {
  display:none
}

zhuzhzh avatar Aug 03 '22 15:08 zhuzhzh

@NGPixel Do you have any timeline on this being implemented?

Explorer1092 avatar Aug 27 '22 11:08 Explorer1092

Would be nice if you could just have the folder element also be the index page, if it exists. I find it hard to put this into words-- But basically, you could expand it to view the subtree by clicking the arrow, and anywhere else would show the index page for that subtree. As an example, you wouldnt have to expand /a containing /a/b to access /a, you could just click it, and remove it visually from the subtree

adroslice avatar Sep 16 '22 08:09 adroslice

I agree with @adroslice.

On another note. I found a bug @myml. if you have a folder that contains the name of another folder then it also opens that folder. lol. eg.

I have a folder/page /Shopware and a folder/page /ShopwareDevDocs. if I open the page for /ShopwareDevDocs then the folder for /Shopware also expands.

davidflypei avatar Nov 23 '22 15:11 davidflypei