mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 04:49:35 +00:00
Fixes #115801 - improves conflict decorations
This commit is contained in:
parent
916c13921d
commit
2fda718ad7
|
@ -2140,6 +2140,15 @@
|
|||
"highContrast": "#c74e39"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "gitDecoration.renamedResourceForeground",
|
||||
"description": "%colors.renamed%",
|
||||
"defaults": {
|
||||
"light": "#007100",
|
||||
"dark": "#73C991",
|
||||
"highContrast": "#73C991"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "gitDecoration.untrackedResourceForeground",
|
||||
"description": "%colors.untracked%",
|
||||
|
@ -2180,9 +2189,9 @@
|
|||
"id": "gitDecoration.conflictingResourceForeground",
|
||||
"description": "%colors.conflict%",
|
||||
"defaults": {
|
||||
"light": "#6c6cc4",
|
||||
"dark": "#6c6cc4",
|
||||
"highContrast": "#6c6cc4"
|
||||
"light": "#ad0707",
|
||||
"dark": "#e4676b",
|
||||
"highContrast": "#c74e39"
|
||||
}
|
||||
},
|
||||
{
|
||||
|
|
|
@ -198,6 +198,7 @@
|
|||
"colors.stageModified": "Color for modified resources which have been staged.",
|
||||
"colors.stageDeleted": "Color for deleted resources which have been staged.",
|
||||
"colors.deleted": "Color for deleted resources.",
|
||||
"colors.renamed": "Color for renamed or copied resources.",
|
||||
"colors.untracked": "Color for untracked resources.",
|
||||
"colors.ignored": "Color for ignored resources.",
|
||||
"colors.conflict": "Color for resources with conflicts.",
|
||||
|
|
|
@ -55,13 +55,13 @@ export class Resource implements SourceControlResourceState {
|
|||
case Status.UNTRACKED: return localize('untracked', "Untracked");
|
||||
case Status.IGNORED: return localize('ignored', "Ignored");
|
||||
case Status.INTENT_TO_ADD: return localize('intent to add', "Intent to Add");
|
||||
case Status.BOTH_DELETED: return localize('both deleted', "Both Deleted");
|
||||
case Status.ADDED_BY_US: return localize('added by us', "Added By Us");
|
||||
case Status.DELETED_BY_THEM: return localize('deleted by them', "Deleted By Them");
|
||||
case Status.ADDED_BY_THEM: return localize('added by them', "Added By Them");
|
||||
case Status.DELETED_BY_US: return localize('deleted by us', "Deleted By Us");
|
||||
case Status.BOTH_ADDED: return localize('both added', "Both Added");
|
||||
case Status.BOTH_MODIFIED: return localize('both modified', "Both Modified");
|
||||
case Status.BOTH_DELETED: return localize('both deleted', "Conflict: Both Deleted");
|
||||
case Status.ADDED_BY_US: return localize('added by us', "Conflict: Added By Us");
|
||||
case Status.DELETED_BY_THEM: return localize('deleted by them', "Conflict: Deleted By Them");
|
||||
case Status.ADDED_BY_THEM: return localize('added by them', "Conflict: Added By Them");
|
||||
case Status.DELETED_BY_US: return localize('deleted by us', "Conflict: Deleted By Us");
|
||||
case Status.BOTH_ADDED: return localize('both added', "Conflict: Both Added");
|
||||
case Status.BOTH_MODIFIED: return localize('both modified', "Conflict: Both Modified");
|
||||
default: return '';
|
||||
}
|
||||
}
|
||||
|
@ -199,12 +199,13 @@ export class Resource implements SourceControlResourceState {
|
|||
case Status.DELETED_BY_US:
|
||||
return 'D';
|
||||
case Status.INDEX_COPIED:
|
||||
return 'C';
|
||||
case Status.BOTH_DELETED:
|
||||
case Status.ADDED_BY_US:
|
||||
case Status.ADDED_BY_THEM:
|
||||
case Status.BOTH_ADDED:
|
||||
case Status.BOTH_MODIFIED:
|
||||
return 'C';
|
||||
return '!'; // Using ! instead of ⚠, because the latter looks really bad on windows
|
||||
default:
|
||||
throw new Error('Unknown git status: ' + this.type);
|
||||
}
|
||||
|
@ -223,12 +224,13 @@ export class Resource implements SourceControlResourceState {
|
|||
case Status.INDEX_ADDED:
|
||||
case Status.INTENT_TO_ADD:
|
||||
return new ThemeColor('gitDecoration.addedResourceForeground');
|
||||
case Status.INDEX_COPIED:
|
||||
case Status.INDEX_RENAMED:
|
||||
return new ThemeColor('gitDecoration.renamedResourceForeground');
|
||||
case Status.UNTRACKED:
|
||||
return new ThemeColor('gitDecoration.untrackedResourceForeground');
|
||||
case Status.IGNORED:
|
||||
return new ThemeColor('gitDecoration.ignoredResourceForeground');
|
||||
case Status.INDEX_COPIED:
|
||||
case Status.BOTH_DELETED:
|
||||
case Status.ADDED_BY_US:
|
||||
case Status.DELETED_BY_THEM:
|
||||
|
@ -246,10 +248,10 @@ export class Resource implements SourceControlResourceState {
|
|||
switch (this.type) {
|
||||
case Status.INDEX_MODIFIED:
|
||||
case Status.MODIFIED:
|
||||
case Status.INDEX_COPIED:
|
||||
return 2;
|
||||
case Status.IGNORED:
|
||||
return 3;
|
||||
case Status.INDEX_COPIED:
|
||||
case Status.BOTH_DELETED:
|
||||
case Status.ADDED_BY_US:
|
||||
case Status.DELETED_BY_THEM:
|
||||
|
|
Loading…
Reference in a new issue