Compare commits

...

7 commits

Author SHA1 Message Date
Till Friebe
d566ded402 Release version 1.1.2 2025-08-24 02:52:13 +02:00
Till Friebe
7bd7dd41c0
Merge pull request #20 from TheJusticeMan/master
fixed the colors
2025-08-24 01:41:54 +02:00
Justice Vellacott
185f95f30a I fixed the colors using the css mix function it'll now work on any theme. 2025-08-03 22:23:57 -04:00
friebetill
08e488d425 Release version 1.1.1 2024-02-15 13:39:30 +07:00
Till Friebe
ac4ea85fe0
Merge pull request #13 from blainelewis1/patch-1
Fix bug where files have same name but differing paths
2024-02-15 13:38:53 +07:00
Blaine Lewis
00567dea68
fix bug where files have same name but differing paths 2024-02-08 10:25:22 -05:00
Till Friebe
ad651d827e
Add SyncThing link 2023-11-08 12:52:26 +01:00
6 changed files with 22 additions and 44 deletions

View file

@ -17,7 +17,7 @@ alt="GIF of a demo show this plugin" width="900" />
## Motivation
I created this plugin because I use SyncThing and it bothered me to clean up merge conflicts by hand.
I created this plugin because I use [SyncThing](https://syncthing.net/) and it bothered me to clean up merge conflicts by hand.
## Installation

View file

@ -1,7 +1,7 @@
{
"id": "file-diff",
"name": "File Diff",
"version": "1.1.0",
"version": "1.1.2",
"minAppVersion": "0.15.0",
"description": "Shows the differences between two files..",
"author": "Till Friebe",

View file

@ -1,6 +1,6 @@
{
"name": "obsidian-file-diff",
"version": "1.1.0",
"version": "1.1.2",
"description": "Shows the differences between two files.",
"main": "main.js",
"scripts": {

View file

@ -174,7 +174,7 @@ export default class FileDiffPlugin extends Plugin {
''
);
const originalFile = files.find(
(f) => f.name === originalFileName
(f) => f.name === originalFileName && (file.parent?.path ?? "") === (f.parent?.path ?? "")
);
if (originalFile) {

View file

@ -13,48 +13,24 @@
text-align: right;
}
@media (prefers-color-scheme: light) {
.file-diff__top-line__bg {
background-color: #d9f4ef;
border-radius: 0.25rem; /* 4px */
}
.file-diff_top-line__character {
background-color: #99e1d3;
border-radius: 0.25rem; /* 4px */
}
.file-diff__bottom-line__bg {
background-color: #d9edff;
border-radius: 0.25rem; /* 4px */
}
.file-diff_bottom-line__character {
background-color: #b1d4f2;
border-radius: 0.25rem; /* 4px */
}
.file-diff__top-line__bg {
background-color: color-mix(in srgb, var(--background-primary), #0fc 15%);
border-radius: 0.25rem; /* 4px */
}
@media (prefers-color-scheme: dark) {
.file-diff__top-line__bg {
background-color: #25403b;
border-radius: 0.25rem; /* 4px */
}
.file-diff_top-line__character {
background-color: color-mix(in srgb, var(--background-primary), #0fc 50%);
border-radius: 0.25rem; /* 4px */
}
.file-diff_top-line__character {
background-color: #236559;
border-radius: 0.25rem; /* 4px */
}
.file-diff__bottom-line__bg {
background-color: color-mix(in srgb, var(--background-primary), #08f 15%);
border-radius: 0.25rem; /* 4px */
}
.file-diff__bottom-line__bg {
background-color: #25394b;
border-radius: 0.25rem; /* 4px */
}
.file-diff_bottom-line__character {
background-color: #2e618d;
border-radius: 0.25rem; /* 4px */
}
.file-diff_bottom-line__character {
background-color: color-mix(in srgb, var(--background-primary), #08f 50%);
border-radius: 0.25rem; /* 4px */
}
.file-diff__no-bottom-border {
@ -68,7 +44,7 @@
}
.file-diff__action-line {
color: #919191;
color: var(--text-muted);
}
/* Tailwind CSS */

View file

@ -13,5 +13,7 @@
"1.0.11": "0.15.0",
"1.0.12": "0.15.0",
"1.0.13": "0.15.0",
"1.1.0": "0.15.0"
"1.1.0": "0.15.0",
"1.1.1": "0.15.0",
"1.1.2": "0.15.0"
}