Web reader toolbar

This commit is contained in:
Jackson Harper 2023-12-11 19:43:57 +08:00
parent a8b5764dae
commit 96e5b37018
42 changed files with 307 additions and 58 deletions

View file

@ -0,0 +1,65 @@
import Foundation
import SwiftUI
import Views
struct CustomToolBar: View {
let isArchived: Bool
let archiveAction: () -> Void
let unarchiveAction: () -> Void
let shareAction: () -> Void
let deleteAction: () -> Void
var barColor: Color {
switch ThemeManager.currentTheme {
case .apollo:
return Color.themeMiddleGray
case .dark:
return Color.themeMiddleGray
case .light:
return Color.themeDarkWhiteGray
case .sepia:
return Color.themeDarkWhiteGray
case .system:
return Color.isDarkMode ? Color.themeMiddleGray : Color.themeDarkWhiteGray
}
}
var body: some View {
VStack {
barColor
.frame(height: 0.5)
.frame(maxWidth: .infinity)
HStack(spacing: 0) {
if isArchived {
ToolBarButton(image: Image.toolbarUnarchive, action: unarchiveAction)
} else {
ToolBarButton(image: Image.toolbarArchive, action: archiveAction)
}
ToolBarButton(image: Image.toolbarShare, action: shareAction)
ToolBarButton(image: Image.toolbarTrash, action: deleteAction)
}
.padding(.top, 8)
}
.padding(.bottom, 30)
.background(ThemeManager.currentBgColor)
}
}
struct ToolBarButton: View {
let image: Image
let action: () -> Void
var body: some View {
Button(action: {
action()
}, label: {
image
.resizable()
.renderingMode(.template)
.aspectRatio(contentMode: .fit)
.frame(width: 28, height: 28)
.foregroundColor(ThemeManager.currentTheme.toolbarColor)
.frame(maxWidth: .infinity)
})
}
}

View file

@ -28,7 +28,7 @@ struct WebReaderContainerView: View {
@State var showExpandedAudioPlayer = false
@State var shareActionID: UUID?
@State var annotation = String()
@State var showBottomBar = false
@State var showBottomBar = true
@State private var bottomBarOpacity = 0.0
@State private var errorAlertMessage: String?
@State private var showErrorAlertMessage = false
@ -160,7 +160,7 @@ struct WebReaderContainerView: View {
var textToSpeechButtonImage: some View {
if audioController.playbackError || audioController.state == .stopped || audioController.itemAudioProperties?.itemID != self.item.id {
return AnyView(Image.headphones)
return AnyView(Image.headphones.frame(width: 48, height: 48))
}
let name = audioController.isPlayingItem(itemID: item.unwrappedID) ? "pause.circle" : "play.circle"
return AnyView(Image(systemName: name).font(.appNavbarIcon))
@ -361,7 +361,7 @@ struct WebReaderContainerView: View {
.tint(Color(hex: "#2A2A2A"))
.frame(height: readerViewNavBarHeight)
.frame(maxWidth: .infinity)
.foregroundColor(ThemeManager.currentTheme.isDark ? .white : .black)
.foregroundColor(ThemeManager.currentTheme.toolbarColor)
.background(ThemeManager.currentBgColor)
.sheet(isPresented: $showLabelsModal) {
ApplyLabelsView(mode: .item(item), onSave: { labels in
@ -592,30 +592,24 @@ struct WebReaderContainerView: View {
.offset(y: navBarVisible ? 0 : -150)
Spacer()
if showBottomBar {
bottomButtons
.frame(height: 48)
.background(Color.webControlButtonBackground)
.cornerRadius(6)
.padding(.bottom, 34)
.shadow(color: .gray.opacity(0.13), radius: 8, x: 0, y: 4)
.opacity(bottomBarOpacity)
.onAppear {
withAnimation(Animation.linear(duration: 0.25)) { self.bottomBarOpacity = 1 }
}
.onDisappear {
self.bottomBarOpacity = 0
}
}
if let audioProperties = audioController.itemAudioProperties {
MiniPlayerViewer(itemAudioProperties: audioProperties)
.padding(.top, 10)
.padding(.bottom, 40)
.padding(.bottom, showBottomBar ? 10 : 40)
.background(Color.themeTabBarColor)
.onTapGesture {
showExpandedAudioPlayer = true
}
}
if showBottomBar {
CustomToolBar(
isArchived: item.isArchived,
archiveAction: archive,
unarchiveAction: archive,
shareAction: share,
deleteAction: delete
)
}
}
#endif
@ -657,7 +651,8 @@ struct WebReaderContainerView: View {
}
func archive() {
dataService.archiveLink(objectID: item.objectID, archived: !item.isArchived)
let isArchived = item.isArchived
dataService.archiveLink(objectID: item.objectID, archived: !isArchived)
#if os(iOS)
pop()
#endif

View file

@ -13,6 +13,12 @@ public extension Image {
static var tabHighlights: Image { Image("_tab_highlights", bundle: .module).renderingMode(.template) }
static var tabProfile: Image { Image("_tab_profile", bundle: .module).renderingMode(.template) }
static var toolbarArchive: Image { Image("toolbar-archive", bundle: .module).renderingMode(.template) }
static var toolbarUnarchive: Image { Image("toolbar-unarchive", bundle: .module).renderingMode(.template) }
static var toolbarShare: Image { Image("toolbar-share", bundle: .module).renderingMode(.template) }
static var toolbarTrash: Image { Image("toolbar-trash", bundle: .module).renderingMode(.template) }
static var pinRotated: Image { Image("pin-rotated", bundle: .module) }
static var chevronRight: Image { Image("chevron-right", bundle: .module) }

View file

@ -1,15 +0,0 @@
{
"images" : [
{
"filename" : "chart-line-up.svg",
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"template-rendering-intent" : "template"
}
}

View file

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="32" height="32" viewBox="0 0 32 32" version="1.1">
<g id="surface1">
<path style="fill:none;stroke-width:16;stroke-linecap:round;stroke-linejoin:round;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:4;" d="M 224 208 L 32 208 L 32 48 " transform="matrix(0.125,0,0,0.125,0,0)"/>
<path style="fill:none;stroke-width:16;stroke-linecap:round;stroke-linejoin:round;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:4;" d="M 208 64 L 128 144 L 96 112 L 32 176 " transform="matrix(0.125,0,0,0.125,0,0)"/>
<path style="fill:none;stroke-width:16;stroke-linecap:round;stroke-linejoin:round;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:4;" d="M 208 104 L 208 64 L 168 64 " transform="matrix(0.125,0,0,0.125,0,0)"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 869 B

View file

@ -1,17 +1,15 @@
{
"images" : [
{
"filename" : "headphones.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "headphones@2x.png",
"filename" : "PlayCircle.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "headphones@3x.png",
"idiom" : "universal",
"scale" : "3x"
}

View file

@ -0,0 +1,3 @@
<svg width="26" height="26" viewBox="0 0 26 26" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M13 2.4375C10.9109 2.4375 8.86879 3.05698 7.13179 4.2176C5.3948 5.37822 4.04098 7.02786 3.24153 8.95791C2.44208 10.8879 2.2329 13.0117 2.64046 15.0606C3.04802 17.1096 4.054 18.9916 5.53119 20.4688C7.00838 21.946 8.89044 22.952 10.9394 23.3595C12.9883 23.7671 15.1121 23.5579 17.0421 22.7585C18.9721 21.959 20.6218 20.6052 21.7824 18.8682C22.943 17.1312 23.5625 15.0891 23.5625 13C23.5595 10.1996 22.4458 7.51466 20.4656 5.53445C18.4853 3.55424 15.8004 2.44046 13 2.4375ZM13 21.9375C11.2323 21.9375 9.50436 21.4133 8.0346 20.4313C6.56483 19.4492 5.41929 18.0533 4.74283 16.4202C4.06637 14.7871 3.88938 12.9901 4.23424 11.2564C4.57909 9.52268 5.43031 7.93016 6.68024 6.68023C7.93017 5.4303 9.52268 4.57909 11.2564 4.23423C12.9901 3.88938 14.7871 4.06637 16.4202 4.74283C18.0534 5.41928 19.4492 6.56483 20.4313 8.03459C21.4133 9.50435 21.9375 11.2323 21.9375 13C21.9348 15.3695 20.9923 17.6413 19.3168 19.3168C17.6413 20.9923 15.3696 21.9348 13 21.9375ZM16.7009 12.3236L11.8259 9.07359C11.7036 8.99193 11.5613 8.94504 11.4143 8.93792C11.2674 8.9308 11.1212 8.96372 10.9915 9.03317C10.8618 9.10261 10.7534 9.20597 10.6778 9.33222C10.6023 9.45847 10.5624 9.60287 10.5625 9.75V16.25C10.5624 16.3971 10.6023 16.5415 10.6778 16.6678C10.7534 16.794 10.8618 16.8974 10.9915 16.9668C11.1212 17.0363 11.2674 17.0692 11.4143 17.0621C11.5613 17.055 11.7036 17.0081 11.8259 16.9264L16.7009 13.6764C16.8124 13.6022 16.9038 13.5017 16.967 13.3837C17.0302 13.2657 17.0633 13.1339 17.0633 13C17.0633 12.8661 17.0302 12.7343 16.967 12.6163C16.9038 12.4983 16.8124 12.3978 16.7009 12.3236ZM12.1875 14.7316V11.2734L14.7855 13L12.1875 14.7316Z" fill="#D9D9D9"/>
</svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 622 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

View file

@ -1,17 +1,15 @@
{
"images" : [
{
"filename" : "label.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "label@2x.png",
"filename" : "label.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "label@3x.png",
"idiom" : "universal",
"scale" : "3x"
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 499 B

View file

@ -0,0 +1,11 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6900_31784)">
<path d="M8.5 9.5C9.05228 9.5 9.5 9.05228 9.5 8.5C9.5 7.94772 9.05228 7.5 8.5 7.5C7.94772 7.5 7.5 7.94772 7.5 8.5C7.5 9.05228 7.94772 9.5 8.5 9.5Z" fill="black" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M4 7V10.859C4 11.396 4.213 11.911 4.593 12.291L12.709 20.407C12.897 20.5951 13.1203 20.7443 13.366 20.846C13.6117 20.9478 13.875 21.0002 14.141 21.0002C14.407 21.0002 14.6703 20.9478 14.916 20.846C15.1617 20.7443 15.385 20.5951 15.573 20.407L20.407 15.573C20.5951 15.385 20.7443 15.1617 20.846 14.916C20.9478 14.6703 21.0002 14.407 21.0002 14.141C21.0002 13.875 20.9478 13.6117 20.846 13.366C20.7443 13.1203 20.5951 12.897 20.407 12.709L12.29 4.593C11.9104 4.2135 11.3957 4.00021 10.859 4H7C6.20435 4 5.44129 4.31607 4.87868 4.87868C4.31607 5.44129 4 6.20435 4 7Z" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6900_31784">
<rect width="24" height="24" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 815 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

View file

@ -1,17 +1,15 @@
{
"images" : [
{
"filename" : "notebooks.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "notebooks@2x.png",
"filename" : "notebook.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "notebooks@3x.png",
"idiom" : "universal",
"scale" : "3x"
}

View file

@ -0,0 +1,3 @@
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M15.8125 9.625C15.8125 9.80734 15.7401 9.9822 15.6111 10.1111C15.4822 10.2401 15.3073 10.3125 15.125 10.3125H9.625C9.44266 10.3125 9.2678 10.2401 9.13886 10.1111C9.00993 9.9822 8.9375 9.80734 8.9375 9.625C8.9375 9.44266 9.00993 9.2678 9.13886 9.13886C9.2678 9.00993 9.44266 8.9375 9.625 8.9375H15.125C15.3073 8.9375 15.4822 9.00993 15.6111 9.13886C15.7401 9.2678 15.8125 9.44266 15.8125 9.625ZM15.125 11.6875H9.625C9.44266 11.6875 9.2678 11.7599 9.13886 11.8889C9.00993 12.0178 8.9375 12.1927 8.9375 12.375C8.9375 12.5573 9.00993 12.7322 9.13886 12.8611C9.2678 12.9901 9.44266 13.0625 9.625 13.0625H15.125C15.3073 13.0625 15.4822 12.9901 15.6111 12.8611C15.7401 12.7322 15.8125 12.5573 15.8125 12.375C15.8125 12.1927 15.7401 12.0178 15.6111 11.8889C15.4822 11.7599 15.3073 11.6875 15.125 11.6875ZM19.25 4.125V17.875C19.25 18.2397 19.1051 18.5894 18.8473 18.8473C18.5894 19.1051 18.2397 19.25 17.875 19.25H4.125C3.76033 19.25 3.41059 19.1051 3.15273 18.8473C2.89487 18.5894 2.75 18.2397 2.75 17.875V4.125C2.75 3.76033 2.89487 3.41059 3.15273 3.15273C3.41059 2.89487 3.76033 2.75 4.125 2.75H17.875C18.2397 2.75 18.5894 2.89487 18.8473 3.15273C19.1051 3.41059 19.25 3.76033 19.25 4.125ZM4.125 17.875H6.1875V4.125H4.125V17.875ZM17.875 17.875V4.125H7.5625V17.875H17.875Z" fill="#D9D9D9"/>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 437 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 660 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 861 B

View file

@ -1,17 +1,15 @@
{
"images" : [
{
"filename" : "reader-settings.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "reader-settings@2x.png",
"filename" : "reader-settings.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "reader-settings@3x.png",
"idiom" : "universal",
"scale" : "3x"
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 440 B

View file

@ -0,0 +1,3 @@
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.20695 15.404C5.28865 15.4425 5.37714 15.4646 5.46737 15.4689C5.55759 15.4732 5.64778 15.4597 5.73277 15.4291C5.81777 15.3985 5.89591 15.3515 5.96273 15.2907C6.02954 15.23 6.08373 15.1566 6.12219 15.0749L7.55391 12.0318H14.4461L15.8778 15.0749C15.9163 15.1566 15.9705 15.2299 16.0373 15.2907C16.1041 15.3514 16.1823 15.3984 16.2673 15.429C16.3522 15.4596 16.4424 15.4731 16.5326 15.4688C16.6229 15.4645 16.7113 15.4425 16.793 15.404C16.8748 15.3655 16.9481 15.3113 17.0088 15.2445C17.0696 15.1777 17.1166 15.0996 17.1472 15.0146C17.1777 14.9296 17.1913 14.8394 17.187 14.7492C17.1827 14.659 17.1607 14.5705 17.1222 14.4888L11.6222 2.80128C11.5667 2.68317 11.4787 2.5833 11.3685 2.51335C11.2583 2.4434 11.1305 2.40625 11 2.40625C10.8695 2.40625 10.7417 2.4434 10.6315 2.51335C10.5213 2.5833 10.4333 2.68317 10.3778 2.80128L4.87781 14.4888C4.8393 14.5705 4.81726 14.659 4.81295 14.7492C4.80865 14.8394 4.82217 14.9296 4.85274 15.0146C4.8833 15.0996 4.93032 15.1777 4.9911 15.2446C5.05188 15.3114 5.12522 15.3656 5.20695 15.404ZM11 4.70909L13.799 10.6568H8.20102L11 4.70909ZM19.25 18.9068C19.25 19.0892 19.1776 19.264 19.0486 19.393C18.9197 19.5219 18.7448 19.5943 18.5625 19.5943H3.4375C3.25516 19.5943 3.0803 19.5219 2.95136 19.393C2.82243 19.264 2.75 19.0892 2.75 18.9068C2.75 18.7245 2.82243 18.5496 2.95136 18.4207C3.0803 18.2918 3.25516 18.2193 3.4375 18.2193H18.5625C18.7448 18.2193 18.9197 18.2918 19.0486 18.4207C19.1776 18.5496 19.25 18.7245 19.25 18.9068Z" fill="#D9D9D9"/>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 628 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 771 B

View file

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "three-dots.svg",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

View file

@ -0,0 +1,12 @@
<svg width="25" height="26" viewBox="0 0 25 26" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6900_31794)">
<path d="M4.16663 13.0007C4.16663 13.2769 4.27637 13.5419 4.47172 13.7372C4.66707 13.9326 4.93203 14.0423 5.20829 14.0423C5.48456 14.0423 5.74951 13.9326 5.94486 13.7372C6.14021 13.5419 6.24996 13.2769 6.24996 13.0007C6.24996 12.7244 6.14021 12.4594 5.94486 12.2641C5.74951 12.0687 5.48456 11.959 5.20829 11.959C4.93203 11.959 4.66707 12.0687 4.47172 12.2641C4.27637 12.4594 4.16663 12.7244 4.16663 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M11.4584 13.0007C11.4584 13.2769 11.5681 13.5419 11.7635 13.7372C11.9588 13.9326 12.2238 14.0423 12.5 14.0423C12.7763 14.0423 13.0413 13.9326 13.2366 13.7372C13.432 13.5419 13.5417 13.2769 13.5417 13.0007C13.5417 12.7244 13.432 12.4594 13.2366 12.2641C13.0413 12.0687 12.7763 11.959 12.5 11.959C12.2238 11.959 11.9588 12.0687 11.7635 12.2641C11.5681 12.4594 11.4584 12.7244 11.4584 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M18.75 13.0007C18.75 13.2769 18.8597 13.5419 19.0551 13.7372C19.2504 13.9326 19.5154 14.0423 19.7917 14.0423C20.0679 14.0423 20.3329 13.9326 20.5282 13.7372C20.7236 13.5419 20.8333 13.2769 20.8333 13.0007C20.8333 12.7244 20.7236 12.4594 20.5282 12.2641C20.3329 12.0687 20.0679 11.959 19.7917 11.959C19.5154 11.959 19.2504 12.0687 19.0551 12.2641C18.8597 12.4594 18.75 12.7244 18.75 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6900_31794">
<rect width="25" height="25" fill="white" transform="translate(0 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

View file

@ -0,0 +1,24 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "toolbar-archive.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"template-rendering-intent" : "template"
}
}

View file

@ -0,0 +1,12 @@
<svg width="29" height="29" viewBox="0 0 29 29" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6896_30722)">
<path d="M4 7.49935C4 6.88051 4.24583 6.28702 4.68342 5.84943C5.121 5.41185 5.71449 5.16602 6.33333 5.16602H22.6667C23.2855 5.16602 23.879 5.41185 24.3166 5.84943C24.7542 6.28702 25 6.88051 25 7.49935C25 8.11819 24.7542 8.71168 24.3166 9.14926C23.879 9.58685 23.2855 9.83268 22.6667 9.83268H6.33333C5.71449 9.83268 5.121 9.58685 4.68342 9.14926C4.24583 8.71168 4 8.11819 4 7.49935Z" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M6.33325 9.83398V21.5007C6.33325 22.1195 6.57908 22.713 7.01667 23.1506C7.45425 23.5882 8.04775 23.834 8.66659 23.834H20.3333C20.9521 23.834 21.5456 23.5882 21.9832 23.1506C22.4208 22.713 22.6666 22.1195 22.6666 21.5007V9.83398" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M12.1667 14.5H16.8334" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6896_30722">
<rect width="28" height="28" fill="white" transform="translate(0.5 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

@ -0,0 +1,24 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "toolbar-share.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"template-rendering-intent" : "template"
}
}

View file

@ -0,0 +1,12 @@
<svg width="29" height="29" viewBox="0 0 29 29" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6896_30728)">
<path d="M9.83325 11H8.66659C8.04775 11 7.45425 11.2458 7.01667 11.6834C6.57908 12.121 6.33325 12.7145 6.33325 13.3333V22.6667C6.33325 23.2855 6.57908 23.879 7.01667 24.3166C7.45425 24.7542 8.04775 25 8.66659 25H20.3333C20.9521 25 21.5456 24.7542 21.9832 24.3166C22.4208 23.879 22.6666 23.2855 22.6666 22.6667V13.3333C22.6666 12.7145 22.4208 12.121 21.9832 11.6834C21.5456 11.2458 20.9521 11 20.3333 11H19.1666" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M14.5 16.8333V4" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M11 7.5L14.5 4L18 7.5" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6896_30728">
<rect width="28" height="28" fill="white" transform="translate(0.5 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1,010 B

View file

@ -0,0 +1,24 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "toolbar-trash.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"template-rendering-intent" : "template"
}
}

View file

@ -0,0 +1,14 @@
<svg width="29" height="29" viewBox="0 0 29 29" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6896_30734)">
<path d="M5.16663 8.66602H23.8333" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M12.1666 13.334V20.334" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M16.8334 13.334V20.334" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M6.33337 8.66602L7.50004 22.666C7.50004 23.2849 7.74587 23.8783 8.18346 24.3159C8.62104 24.7535 9.21454 24.9993 9.83337 24.9993H19.1667C19.7855 24.9993 20.379 24.7535 20.8166 24.3159C21.2542 23.8783 21.5 23.2849 21.5 22.666L22.6667 8.66602" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M11 8.66667V5.16667C11 4.85725 11.1229 4.5605 11.3417 4.34171C11.5605 4.12292 11.8572 4 12.1667 4H16.8333C17.1428 4 17.4395 4.12292 17.6583 4.34171C17.8771 4.5605 18 4.85725 18 5.16667V8.66667" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6896_30734">
<rect width="28" height="28" fill="white" transform="translate(0.5 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

@ -0,0 +1,24 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "toolbar-unarchive.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
},
"properties" : {
"template-rendering-intent" : "template"
}
}

View file

@ -0,0 +1,13 @@
<svg width="29" height="29" viewBox="0 0 29 29" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6900_31839)">
<path d="M9.8335 5.16602H22.6668C23.2857 5.16602 23.8792 5.41185 24.3167 5.84943C24.7543 6.28702 25.0002 6.88051 25.0002 7.49935C25.0002 8.11819 24.7543 8.71168 24.3167 9.14926C23.8792 9.58685 23.2857 9.83268 22.6668 9.83268H14.5002M9.8335 9.83268H6.3335C5.80004 9.833 5.28258 9.65051 4.86733 9.31562C4.45208 8.98073 4.16412 8.51367 4.05144 7.99224C3.93875 7.47082 4.00813 6.92653 4.24803 6.45005C4.48793 5.97357 4.88385 5.59368 5.36983 5.37368" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M6.3335 9.83398V21.5007C6.3335 22.1195 6.57933 22.713 7.01691 23.1506C7.4545 23.5882 8.04799 23.834 8.66683 23.834H20.3335C20.7831 23.8339 21.2232 23.704 21.6007 23.4598C21.9782 23.2155 22.2771 22.8674 22.4615 22.4573M22.6668 18.0007V9.83398" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M12.1667 14.5H14.5001" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M4.00012 4L25.0001 25" stroke="#3D3D3D" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6900_31839">
<rect width="28" height="28" fill="white" transform="translate(0.500122 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

@ -1,17 +1,15 @@
{
"images" : [
{
"filename" : "utility-menu.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "utility-menu@2x.png",
"filename" : "three-dots.svg",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "utility-menu@3x.png",
"idiom" : "universal",
"scale" : "3x"
}

View file

@ -0,0 +1,12 @@
<svg width="25" height="26" viewBox="0 0 25 26" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_6900_31794)">
<path d="M4.16663 13.0007C4.16663 13.2769 4.27637 13.5419 4.47172 13.7372C4.66707 13.9326 4.93203 14.0423 5.20829 14.0423C5.48456 14.0423 5.74951 13.9326 5.94486 13.7372C6.14021 13.5419 6.24996 13.2769 6.24996 13.0007C6.24996 12.7244 6.14021 12.4594 5.94486 12.2641C5.74951 12.0687 5.48456 11.959 5.20829 11.959C4.93203 11.959 4.66707 12.0687 4.47172 12.2641C4.27637 12.4594 4.16663 12.7244 4.16663 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M11.4584 13.0007C11.4584 13.2769 11.5681 13.5419 11.7635 13.7372C11.9588 13.9326 12.2238 14.0423 12.5 14.0423C12.7763 14.0423 13.0413 13.9326 13.2366 13.7372C13.432 13.5419 13.5417 13.2769 13.5417 13.0007C13.5417 12.7244 13.432 12.4594 13.2366 12.2641C13.0413 12.0687 12.7763 11.959 12.5 11.959C12.2238 11.959 11.9588 12.0687 11.7635 12.2641C11.5681 12.4594 11.4584 12.7244 11.4584 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M18.75 13.0007C18.75 13.2769 18.8597 13.5419 19.0551 13.7372C19.2504 13.9326 19.5154 14.0423 19.7917 14.0423C20.0679 14.0423 20.3329 13.9326 20.5282 13.7372C20.7236 13.5419 20.8333 13.2769 20.8333 13.0007C20.8333 12.7244 20.7236 12.4594 20.5282 12.2641C20.3329 12.0687 20.0679 11.959 19.7917 11.959C19.5154 11.959 19.2504 12.0687 19.0551 12.2641C18.8597 12.4594 18.75 12.7244 18.75 13.0007Z" fill="#D9D9D9" stroke="#D9D9D9" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
</g>
<defs>
<clipPath id="clip0_6900_31794">
<rect width="25" height="25" fill="white" transform="translate(0 0.5)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 604 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

View file

@ -31,6 +31,10 @@ public enum Theme: String, CaseIterable {
}
}
public var toolbarColor: Color {
ThemeManager.currentTheme.isDark ? Color.themeDarkWhiteGray : Color.themeMiddleGray
}
public var highlightColor: Color {
switch self {
case .light, .sepia: