mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-12-03 14:59:57 +00:00
Improved status messages in ImportListing to remove redundant and irrelevant messages (#5059)
This commit is contained in:
parent
b95f9e6000
commit
527638d5e6
@ -18,11 +18,11 @@ Listing/Rename/Prompt: Rename to:
|
|||||||
Listing/Rename/ConfirmRename: Rename tiddler
|
Listing/Rename/ConfirmRename: Rename tiddler
|
||||||
Listing/Rename/CancelRename: Cancel
|
Listing/Rename/CancelRename: Cancel
|
||||||
Listing/Rename/OverwriteWarning: A tiddler with this title already exists.
|
Listing/Rename/OverwriteWarning: A tiddler with this title already exists.
|
||||||
Upgrader/Plugins/Suppressed/Incompatible: Blocked incompatible or obsolete plugin
|
Upgrader/Plugins/Suppressed/Incompatible: Blocked incompatible or obsolete plugin.
|
||||||
Upgrader/Plugins/Suppressed/Version: Blocked plugin (due to incoming <<incoming>> being older than existing <<existing>>)
|
Upgrader/Plugins/Suppressed/Version: Blocked plugin (due to incoming <<incoming>> not being newer than existing <<existing>>).
|
||||||
Upgrader/Plugins/Upgraded: Upgraded plugin from <<incoming>> to <<upgraded>>
|
Upgrader/Plugins/Upgraded: Upgraded plugin from <<incoming>> to <<upgraded>>.
|
||||||
Upgrader/State/Suppressed: Blocked temporary state tiddler
|
Upgrader/State/Suppressed: Blocked temporary state tiddler.
|
||||||
Upgrader/System/Suppressed: Blocked system tiddler
|
Upgrader/System/Suppressed: Blocked system tiddler.
|
||||||
Upgrader/System/Warning: Core module tiddler
|
Upgrader/System/Warning: Core module tiddler.
|
||||||
Upgrader/System/Alert: You are about to import a tiddler that will overwrite a core module tiddler. This is not recommended as it may make the system unstable
|
Upgrader/System/Alert: You are about to import a tiddler that will overwrite a core module tiddler. This is not recommended as it may make the system unstable.
|
||||||
Upgrader/ThemeTweaks/Created: Migrated theme tweak from <$text text=<<from>>/>
|
Upgrader/ThemeTweaks/Created: Migrated theme tweak from <$text text=<<from>>/>.
|
||||||
|
@ -57,7 +57,7 @@ exports.upgrade = function(wiki,titles,tiddlers) {
|
|||||||
// Reject the incoming plugin by blanking all its fields
|
// Reject the incoming plugin by blanking all its fields
|
||||||
if($tw.utils.checkVersions(existingTiddler.fields.version,incomingTiddler.version)) {
|
if($tw.utils.checkVersions(existingTiddler.fields.version,incomingTiddler.version)) {
|
||||||
tiddlers[title] = Object.create(null);
|
tiddlers[title] = Object.create(null);
|
||||||
messages[title] = requiresReload + $tw.language.getString("Import/Upgrader/Plugins/Suppressed/Version",{variables: {incoming: incomingTiddler.version, existing: existingTiddler.fields.version}});
|
messages[title] = $tw.language.getString("Import/Upgrader/Plugins/Suppressed/Version",{variables: {incoming: incomingTiddler.version, existing: existingTiddler.fields.version}});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -529,6 +529,7 @@ NavigatorWidget.prototype.handleImportTiddlersEvent = function(event) {
|
|||||||
$tw.utils.each(importData.tiddlers,function(tiddler,title) {
|
$tw.utils.each(importData.tiddlers,function(tiddler,title) {
|
||||||
if($tw.utils.count(tiddler) === 0) {
|
if($tw.utils.count(tiddler) === 0) {
|
||||||
newFields["selection-" + title] = "unchecked";
|
newFields["selection-" + title] = "unchecked";
|
||||||
|
newFields["suppressed-" + title] = "yes";
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// Save the $:/Import tiddler
|
// Save the $:/Import tiddler
|
||||||
|
@ -7,13 +7,17 @@ title: $:/core/ui/ImportListing
|
|||||||
\define payloadTitleFilter() [<currentTiddler>get<renameField>minlength[1]else<payloadTiddler>]
|
\define payloadTitleFilter() [<currentTiddler>get<renameField>minlength[1]else<payloadTiddler>]
|
||||||
|
|
||||||
\define overWriteWarning()
|
\define overWriteWarning()
|
||||||
|
<$list filter="[<currentTiddler>!has<suppressedField>]">
|
||||||
<$text text={{{[subfilter<payloadTitleFilter>!is[tiddler]then[]] ~[<lingo-base>addsuffix[Listing/Rename/OverwriteWarning]get[text]]}}}/>
|
<$text text={{{[subfilter<payloadTitleFilter>!is[tiddler]then[]] ~[<lingo-base>addsuffix[Listing/Rename/OverwriteWarning]get[text]]}}}/>
|
||||||
|
</$list>
|
||||||
\end
|
\end
|
||||||
|
|
||||||
\define selectionField() selection-$(payloadTiddler)$
|
\define selectionField() selection-$(payloadTiddler)$
|
||||||
|
|
||||||
\define renameField() rename-$(payloadTiddler)$
|
\define renameField() rename-$(payloadTiddler)$
|
||||||
|
|
||||||
|
\define suppressedField() suppressed-$(payloadTiddler)$
|
||||||
|
|
||||||
\define newImportTitleTiddler() $:/temp/NewImportTitle-$(payloadTiddler)$
|
\define newImportTitleTiddler() $:/temp/NewImportTitle-$(payloadTiddler)$
|
||||||
|
|
||||||
\define previewPopupState() $(currentTiddler)$!!popup-$(payloadTiddler)$
|
\define previewPopupState() $(currentTiddler)$!!popup-$(payloadTiddler)$
|
||||||
@ -44,15 +48,15 @@ title: $:/core/ui/ImportListing
|
|||||||
<$list filter="[all[current]plugintiddlers[]sort[title]]" variable="payloadTiddler">
|
<$list filter="[all[current]plugintiddlers[]sort[title]]" variable="payloadTiddler">
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<$checkbox field=<<selectionField>> checked="checked" unchecked="unchecked" default="checked"/>
|
<$checkbox field=<<selectionField>> checked="checked" unchecked="unchecked" default="checked" disabled={{{[<currentTiddler>has<suppressedField>then[yes]else[no]]}}}/>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<$reveal type="nomatch" state=<<renameFieldState>> text="yes" tag="div">
|
<$reveal type="nomatch" state=<<renameFieldState>> text="yes" tag="div">
|
||||||
<$reveal type="nomatch" state=<<previewPopupState>> text="yes" tag="div" class="tc-flex">
|
<$reveal type="nomatch" state=<<previewPopupState>> text="yes" tag="div" class="tc-flex">
|
||||||
<$button class="tc-btn-invisible tc-btn-dropdown tc-flex-grow-1 tc-word-break" set=<<previewPopupState>> setTo="yes">
|
<$button class="tc-btn-invisible tc-btn-dropdown tc-flex-grow-1 tc-word-break" set=<<previewPopupState>> setTo="yes" disabled={{{[<currentTiddler>has<suppressedField>then[yes]else[no]]}}}>
|
||||||
<span class="tc-small-gap-right">{{$:/core/images/right-arrow}}</span><$text text={{{[subfilter<payloadTitleFilter>]}}}/>
|
<span class="tc-small-gap-right">{{$:/core/images/right-arrow}}</span><$text text={{{[subfilter<payloadTitleFilter>]}}}/>
|
||||||
</$button>
|
</$button>
|
||||||
<$button class="tc-btn-invisible" set=<<renameFieldState>> setTo="yes" tooltip={{{[<lingo-base>addsuffix[Listing/Rename/Tooltip]get[text]]}}}>{{$:/core/images/edit-button}}</$button>
|
<$list filter="[<currentTiddler>!has<suppressedField>]"><$button class="tc-btn-invisible" set=<<renameFieldState>> setTo="yes" tooltip={{{[<lingo-base>addsuffix[Listing/Rename/Tooltip]get[text]]}}}>{{$:/core/images/edit-button}}</$button></$list>
|
||||||
</$reveal>
|
</$reveal>
|
||||||
<$reveal type="match" state=<<previewPopupState>> text="yes" tag="div">
|
<$reveal type="match" state=<<previewPopupState>> text="yes" tag="div">
|
||||||
<$button class="tc-btn-invisible tc-btn-dropdown" set=<<previewPopupState>> setTo="no">
|
<$button class="tc-btn-invisible tc-btn-dropdown" set=<<previewPopupState>> setTo="no">
|
||||||
|
Loading…
Reference in New Issue
Block a user