Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pagesettingsmenu to rightsidebar #93

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion webApp/src/main/scala/wust/webApp/views/PageHeader.scala
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ object PageHeader {

VDomModifier(
pinButton,
PageSettingsMenu(channelId).apply(buttonStyle, fontSize := "20px"),
// PageSettingsMenu(channelId).apply(buttonStyle, fontSize := "20px"),
)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ object PageSettingsMenu {
GlobalState.graph().pinnedNodeIdx(userIdx).contains(channelIdx)
}

private def sidebarMenuItems(channelId: NodeId)(implicit ctx: Ctx.Owner) = {
def sidebarMenuItems(channelId: NodeId)(implicit ctx: Ctx.Owner) = {
val isBookmarked = nodeIsBookmarked( channelId)

val channelAsNode: Rx[Option[Node]] = Rx {
Expand Down
11 changes: 9 additions & 2 deletions webApp/src/main/scala/wust/webApp/views/RightSidebar.scala
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package wust.webApp.views

import acyclic.file
import fontAwesome.freeSolid
import outwatch.dom._
import outwatch.dom.dsl._
Expand Down Expand Up @@ -187,7 +186,15 @@ object RightSidebar {
flexDirection.column,
justifyContent.flexStart,
boxShadow := "none", //explicitly overwrite boxshadow from accordion.
)
),
div(
cls := "ui secondary menu",
flexWrap.wrap,
flexDirection.column,
height := "600px",
justifyContent.spaceAround,
PageSettingsMenu.sidebarMenuItems(focusPref.nodeId)
)
)
}
private def viewContent(focusPref: FocusPreference, parentIdAction: Option[NodeId] => Unit, nodeStyle: PageStyle, viewRender: ViewRenderLike)(implicit ctx: Ctx.Owner) = {
Expand Down