diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 61dca9429..cc4de50a2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -354,6 +354,7 @@ jobs: if [ "${{ inputs.update_branch }}" = "twilight" ]; then sed -i -e 's/Name=Zen Browser/Name=Zen Twilight/g' AppDir/zen.desktop + sed -i -e 's/StartupWMClass=zen-alpha/StartupWMClass=zen-twilight/g' AppDir/zen.desktop fi APPDIR=AppDir diff --git a/README.md b/README.md index bd3da6514..2cb8d1842 100644 --- a/README.md +++ b/README.md @@ -103,6 +103,7 @@ Special thanks to... EVERYONE 🎉! Checkout the team and contributors page [her Zen couldn't be in its current state without the help of these amazing projects! 🙏 - Zen's default preferences are based on [BetterFox](https://github.com/yokoffing/Betterfox) +- Icon Pack provided by [Microsoft's FluentUI System Icons](https://github.com/microsoft/fluentui-system-icons) ### 🖥️ Comparison with other browsers diff --git a/scripts/prepare-flatpak-release.py b/scripts/prepare-flatpak-release.py index 4a3da1379..9deec6319 100644 --- a/scripts/prepare-flatpak-release.py +++ b/scripts/prepare-flatpak-release.py @@ -1,13 +1,11 @@ - -import os -import sys - import hashlib import argparse +import sys FLATID = "io.github.zen_browser.zen" def get_sha256sum(filename): + """Calculate the SHA256 checksum of a file.""" sha256 = hashlib.sha256() with open(filename, "rb") as f: for byte_block in iter(lambda: f.read(4096), b""): @@ -25,10 +23,12 @@ def build_template(template, linux_sha256, flatpak_sha256, version): def get_template(template_root): file = f"{template_root}/{FLATID}.yml.template" print(f"Reading template {file}") - with open(file, "r") as f: - return f.read() - print(f"Template {template_root}/flatpak.yml not found") - sys.exit(1) + try: + with open(file, "r") as f: + return f.read() + except FileNotFoundError: + print(f"Template {file} not found") + sys.exit(1) def main(): parser = argparse.ArgumentParser(description='Prepare flatpak release') @@ -39,20 +39,14 @@ def main(): parser.add_argument('--template-root', help='Template root', default="flatpak") args = parser.parse_args() - version = args.version - linux_archive = args.linux_archive - flatpak_archive = args.flatpak_archive - output = args.output - template_root = args.template_root + linux_sha256 = get_sha256sum(args.linux_archive) + flatpak_sha256 = get_sha256sum(args.flatpak_archive) + template = build_template(get_template(args.template_root), linux_sha256, flatpak_sha256, args.version) - linux_sha256 = get_sha256sum(linux_archive) - flatpak_sha256 = get_sha256sum(flatpak_archive) - - template = build_template(get_template(template_root), linux_sha256, flatpak_sha256, version) - - print(f"Writing output to {output}") - with open(output, "w") as f: + print(f"Writing output to {args.output}") + with open(args.output, "w") as f: f.write(template) if __name__ == "__main__": main() + diff --git a/src/browser/base/content/zen-popupset.inc.xhtml b/src/browser/base/content/zen-popupset.inc.xhtml index c74bf7e01..2fe1b2a20 100644 --- a/src/browser/base/content/zen-popupset.inc.xhtml +++ b/src/browser/base/content/zen-popupset.inc.xhtml @@ -103,25 +103,23 @@ - + -

+

+ + +
- - -
- -

- -
+ +
diff --git a/src/browser/base/content/zen-styles/zen-tabs/vertical-tabs.css b/src/browser/base/content/zen-styles/zen-tabs/vertical-tabs.css index 60af5c5f0..2740ab478 100644 --- a/src/browser/base/content/zen-styles/zen-tabs/vertical-tabs.css +++ b/src/browser/base/content/zen-styles/zen-tabs/vertical-tabs.css @@ -49,7 +49,7 @@ content: ''; display: block; height: 1px; - + margin: 0 auto; width: 80%; left: 50%; @@ -58,7 +58,6 @@ bottom: calc(-1 * var(--zen-toolbox-padding)); } - @media (-moz-bool-pref: 'zen.view.show-bottom-border') { &::after { background: color-mix(in srgb, var(--zen-colors-border) 70%, transparent 30%); @@ -174,10 +173,12 @@ ) { --zen-toolbox-min-width: fit-content; padding: var(--zen-toolbox-padding); + padding-left: 0 !important; padding-top: 0; & #titlebar { min-width: 150px; + padding-left: var(--zen-toolbox-padding); } & #zen-workspaces-button { diff --git a/src/browser/base/content/zen-styles/zen-workspaces.css b/src/browser/base/content/zen-styles/zen-workspaces.css index 6ceeb67bf..e0aa8890b 100644 --- a/src/browser/base/content/zen-styles/zen-workspaces.css +++ b/src/browser/base/content/zen-styles/zen-workspaces.css @@ -171,7 +171,6 @@ position: relative; padding: 15px; width: var(--panel-width); - min-height: 150px; } #PanelUI-zen-workspaces-icon-picker toolbarbutton { @@ -208,7 +207,7 @@ padding: 5px; display: flex; gap: 10px; - + flex-wrap: wrap; } } @@ -245,7 +244,7 @@ border-right: 1px solid var(--zen-colors-border); margin-right: 2px; } - + & html|input { border: none; outline: none !important; @@ -254,12 +253,7 @@ } } -#PanelUI-zen-workspaces-current-info toolbarbutton:last-child { - margin-bottom: 0 !important; -} - -#PanelUI-zen-workspaces-list toolbarbutton, -#PanelUI-zen-workspaces-current-info toolbarbutton { +#PanelUI-zen-workspaces-list toolbarbutton{ padding: 5px; border-radius: var(--zen-button-border-radius); @@ -268,6 +262,7 @@ display: flex; align-items: center; + position: relative; &:first-child { margin-top: 10px; @@ -303,28 +298,66 @@ font-weight: normal; } - & .zen-workspace-actions { + & .zen-workspace-actions, .zen-workspace-actions-reorder-icon { display: none; margin: 0; margin-left: auto !important; } + + &.zen-workspace-button[active='true'] { + position: relative; + } + + &.zen-workspace-button[active='true']::before { + content: ''; + position: absolute; + top: 0; + left: -6px; + width: 4px; + height: 100%; + background-color: var(--toolbarbutton-icon-fill-attention); + border-radius: 5px; + } +} + +.zen-workspace-button.dragging { + opacity: 0.5; +} + +.zen-workspace-button.dragover::after { + content: ''; + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 4px; + background-color: var(--toolbarbutton-icon-fill-attention); + border-radius: 5px; +} + +#PanelUI-zen-workspaces-reorder-mode[active='true'] { + color: var(--toolbarbutton-icon-fill-attention) !important; +} + +#PanelUI-zen-workspaces-list:not([reorder-mode="true"]) toolbarbutton { &:hover .zen-workspace-actions, & .zen-workspace-actions[active='true'] { display: flex; } } -#PanelUI-zen-workspaces-current-info toolbarbutton:first-child { - margin-bottom: 10px; - margin-top: 5px; +#PanelUI-zen-workspaces-list[reorder-mode="true"] toolbarbutton { + .zen-workspace-actions-reorder-icon { + display: flex; + } } #PanelUI-zen-workspaces-view > vbox:nth-child(2) { margin-top: 10px; } -#PanelUI-zen-workspaces-new { +#PanelUI-zen-workspaces-new, #PanelUI-zen-workspaces-reorder-mode { margin-left: auto; min-height: 1px !important; padding: 3px; diff --git a/src/browser/themes/shared/zen-icons/drag-indicator.svg b/src/browser/themes/shared/zen-icons/drag-indicator.svg new file mode 100644 index 000000000..1a1d1b02c --- /dev/null +++ b/src/browser/themes/shared/zen-icons/drag-indicator.svg @@ -0,0 +1,3 @@ + + + diff --git a/src/browser/themes/shared/zen-icons/icons.css b/src/browser/themes/shared/zen-icons/icons.css index 1cd766438..2535f8e55 100644 --- a/src/browser/themes/shared/zen-icons/icons.css +++ b/src/browser/themes/shared/zen-icons/icons.css @@ -185,6 +185,11 @@ list-style-image: url('plus.svg') !important; } +#PanelUI-zen-workspaces-reorder-mode image { + list-style-image: url('move-tab.svg') !important; + rotate: 90deg; +} + #cut-button { list-style-image: url('edit-cut.svg') !important; } @@ -362,6 +367,10 @@ list-style-image: url('arrow-down.svg') !important; } +.zen-workspace-actions-reorder-icon { + list-style-image: url('drag-indicator.svg') !important; +} + #protections-popup-mainView .subviewbutton-nav:not(.notFound)::after, #identity-popup-mainView .subviewbutton-nav::after, .widget-overflow-list .subviewbutton-nav::after,