mirror of
https://git.srhtnin.garden/sarah/SaraView.git
synced 2026-10-14 18:38:11 +02:00
Added modals for popups, and fixed root-level bug.
This commit is contained in:
1 parent
9736a55e00
commit
104198036a
11 files changed
+312
-62
No files matched your search
@@ -47,6 +47,22 @@ def ResolvePath(RootName: str, RelativePath: str) -> Path:
|
||||
return Candidate
|
||||
|
||||
|
||||
def NormalizeRelativePath(BaseDirectory: str, RawPath: str) -> str:
|
||||
Combined = f"{BaseDirectory}/{RawPath}" if BaseDirectory else RawPath
|
||||
Parts: list[str] = []
|
||||
|
||||
for Part in Combined.split("/"):
|
||||
if Part in ("", "."):
|
||||
continue
|
||||
if Part == "..":
|
||||
if Parts:
|
||||
Parts.pop()
|
||||
continue
|
||||
Parts.append(Part)
|
||||
|
||||
return "/".join(Parts)
|
||||
|
||||
|
||||
def IsInternalPath(EntryPath: Path) -> bool:
|
||||
SaraTagConfig = Config.get("SaraTag", {})
|
||||
|
||||
|
||||
Reference in new issue
Block a user