basic-password-manager 0.4.4__tar.gz → 0.4.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/PKG-INFO +1 -1
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/PKG-INFO +1 -1
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/logo.py +11 -2
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/mobile.py +4 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/tui.py +4 -1
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pyproject.toml +1 -1
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/LICENSE +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/README.md +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/SOURCES.txt +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/dependency_links.txt +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/entry_points.txt +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/requires.txt +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/basic_password_manager.egg-info/top_level.txt +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/__init__.py +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/cli.py +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/crypto.py +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/vault.py +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/web/argon2.umd.min.js +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/web/page.html +0 -0
- {basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: basic-password-manager
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.5
|
|
4
4
|
Summary: The Paladin — a local encrypted password manager that lives in your terminal
|
|
5
5
|
License-Expression: MIT
|
|
6
6
|
Project-URL: Repository, https://github.com/Daisentaur/password-manager
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: basic-password-manager
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.5
|
|
4
4
|
Summary: The Paladin — a local encrypted password manager that lives in your terminal
|
|
5
5
|
License-Expression: MIT
|
|
6
6
|
Project-URL: Repository, https://github.com/Daisentaur/password-manager
|
|
@@ -75,9 +75,18 @@ def _tinted(pixel, tint, accent):
|
|
|
75
75
|
return tuple(int(c * lum) for c in base)
|
|
76
76
|
|
|
77
77
|
|
|
78
|
-
def _hex_rgb(color: str) -> tuple:
|
|
78
|
+
def _hex_rgb(color: str | None) -> tuple | None:
|
|
79
|
+
"""Parse #rrggbb to (r,g,b). Returns None for anything that isn't hex —
|
|
80
|
+
ANSI themes use names like 'ansi_blue', and those just mean 'no tint'."""
|
|
81
|
+
if not color:
|
|
82
|
+
return None
|
|
79
83
|
color = color.lstrip("#")
|
|
80
|
-
|
|
84
|
+
if len(color) != 6:
|
|
85
|
+
return None
|
|
86
|
+
try:
|
|
87
|
+
return tuple(int(color[i : i + 2], 16) for i in (0, 2, 4))
|
|
88
|
+
except ValueError:
|
|
89
|
+
return None
|
|
81
90
|
|
|
82
91
|
|
|
83
92
|
def rich_text(tint: str | None = None, accent: str | None = None) -> Text:
|
|
@@ -130,6 +130,10 @@ def _theme_colors() -> dict:
|
|
|
130
130
|
registry = {t.name: t for t in TUXEDO_THEMES}
|
|
131
131
|
registry.update(BUILTIN_THEMES)
|
|
132
132
|
cs = registry[name].to_color_system().generate()
|
|
133
|
+
# ANSI themes resolve to names like 'ansi_blue', not hex — the browser
|
|
134
|
+
# can't use those and the knight can't tint from them, so fall back
|
|
135
|
+
if not str(cs.get("background", "")).startswith("#"):
|
|
136
|
+
return default
|
|
133
137
|
return {**default, **cs}
|
|
134
138
|
except (OSError, KeyError, ImportError):
|
|
135
139
|
return default
|
|
@@ -103,6 +103,8 @@ class UnlockScreen(Screen):
|
|
|
103
103
|
self.query_one("#master", Input).clear()
|
|
104
104
|
return
|
|
105
105
|
self.app.master = event.value
|
|
106
|
+
# stop repainting the (now-hidden) unlock knight on every theme change
|
|
107
|
+
self.app.theme_changed_signal.unsubscribe(self)
|
|
106
108
|
self.app.push_screen(MainScreen())
|
|
107
109
|
|
|
108
110
|
|
|
@@ -167,7 +169,8 @@ def _qr_text(url: str, primary: str) -> tuple[Text, int]:
|
|
|
167
169
|
must give the widget exactly that width: a wrapped QR is a dead QR."""
|
|
168
170
|
import qrcode
|
|
169
171
|
|
|
170
|
-
|
|
172
|
+
rgb = logo._hex_rgb(primary) or (0, 0, 0) # ansi themes → plain black QR
|
|
173
|
+
r, g, b = rgb
|
|
171
174
|
while (r + g + b) / 765 > 0.45:
|
|
172
175
|
r, g, b = int(r * 0.8), int(g * 0.8), int(b * 0.8)
|
|
173
176
|
dark, light = f"rgb({r},{g},{b})", "rgb(255,255,255)"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{basic_password_manager-0.4.4 → basic_password_manager-0.4.5}/pw_manager/web/argon2.umd.min.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|