Rename highlights + notes to notebook

This commit is contained in:
Jackson Harper
2022-12-01 13:59:29 +08:00
parent ab64e56ab4
commit 2cdd75ac18
4 changed files with 14 additions and 21 deletions

View File

@ -15,7 +15,7 @@ struct HighlightsListView: View {
var emptyView: some View {
Text("""
You have not added any highlights to this page.
You have not added any highlights or notes to this page.
""")
.multilineTextAlignment(.center)
.padding(16)
@ -23,7 +23,7 @@ struct HighlightsListView: View {
var innerBody: some View {
(viewModel.highlightItems.count > 0 ? AnyView(listView) : AnyView(emptyView))
.navigationTitle("Highlights & Notes")
.navigationTitle("Notebook")
.listStyle(PlainListStyle())
#if os(iOS)
.navigationBarTitleDisplayMode(.inline)

View File

@ -271,12 +271,10 @@ import Views
func menuItems(for item: LinkedItem) -> some View {
Group {
if (item.highlights?.count ?? 0) > 0 {
Button(
action: { viewModel.itemForHighlightsView = item },
label: { Label("View Highlights & Notes", systemImage: "highlighter") }
)
}
Button(
action: { viewModel.itemForHighlightsView = item },
label: { Label("Notebook", systemImage: "highlighter") }
)
Button(
action: { viewModel.itemUnderTitleEdit = item },
label: { Label("Edit Info", systemImage: "info.circle") }

View File

@ -177,14 +177,11 @@ struct WebReaderContainerView: View {
func menuItems(for item: LinkedItem) -> some View {
let hasLabels = item.labels?.count == 0
let hasHighlights = (item.highlights?.count ?? 0) > 0
return Group {
if hasHighlights {
Button(
action: { showHighlightsView = true },
label: { Label("View Highlights & Notes", systemImage: "highlighter") }
)
}
Button(
action: { showHighlightsView = true },
label: { Label("Notebook", systemImage: "highlighter") }
)
Button(
action: { showTitleEdit = true },
label: { Label("Edit Info", systemImage: "info.circle") }

View File

@ -45,12 +45,10 @@ public struct GridCard: View {
var contextMenuView: some View {
Group {
if (item.highlights?.count ?? 0) > 0 {
Button(
action: { menuActionHandler(.viewHighlights) },
label: { Label("View Highlights & Notes", systemImage: "highlighter") }
)
}
Button(
action: { menuActionHandler(.viewHighlights) },
label: { Label("Notebook", systemImage: "highlighter") }
)
Button(
action: { menuActionHandler(.editTitle) },
label: { Label("Edit Info", systemImage: "info.circle") }