Content deleted Content added
(bot/CD) |
(bot/CD) |
||
Line 3,663:
var version = "0.4.2";
var gitAbbrevHash = "
var gitBranch = "main";
var gitDate = "
var gitVersion = "0.4.2+
/**
Line 6,298:
validate: /^((?!W(iki)?p(edia)?:(A(rticles)?[ _]?f(or)?[ _]?d(eletion)?\/)).+|$)/gi
}),
date: new mw.widgets.
icon: 'calendar',
value: parsedDate ? `${parsedDate.getUTCFullYear()}-${parsedDate.getUTCMonth() + 1}-${parsedDate.getUTCDate()}` : undefined,
}),
toggle: new OO.ui.ToggleSwitchWidget()
Line 6,457 ⟶ 6,454:
this.copiedTemplateRow[field] = value ? 'yes' : '';
}
else if (input instanceof mw.widgets.
this.copiedTemplateRow[field] = value ?
new Date(value + 'T00:00:00Z').toLocaleDateString('en-GB', {
year: 'numeric', month: 'long', day: 'numeric'
}) : undefined;
if (value.length > 0) {
this.fieldLayouts[field].setWarnings([]);
Line 7,524 ⟶ 7,521:
placeholder: mw.msg('deputy.ante.splitArticle.from_oldid.placeholder')
}),
date: new mw.widgets.
$overlay: this.parent.$overlay,
required: true,
icon: 'calendar',
value: parsedDate ? `${parsedDate.getUTCFullYear()}-${parsedDate.getUTCMonth() + 1}-${parsedDate.getUTCDate()}` : undefined,
}),
diff: new OO.ui.TextInputWidget({
Line 7,584 ⟶ 7,580:
// Attach the change listener
input.on('change', (value) => {
if (input instanceof mw.widgets.
this.splitArticleTemplateRow[field] = value ?
new Date(value + 'T00:00:00Z').toLocaleDateString('en-GB', {
year: 'numeric', month: 'long', day: 'numeric'
}) : undefined;
if (value.length > 0) {
fieldLayouts[field].setWarnings([]);
Line 8,030 ⟶ 8,026:
placeholder: mw.msg('deputy.ante.mergedFrom.article.placeholder')
}),
date: new mw.widgets.
$overlay: this.parent.$overlay,
required: true,
icon: 'calendar',
value: parsedDate ? `${parsedDate.getUTCFullYear()}-${parsedDate.getUTCMonth() + 1}-${parsedDate.getUTCDate()}` : undefined,
}),
target: new mw.widgets.TitleInputWidget({
Line 8,097 ⟶ 8,092:
this.mergedFromTemplate[field] = value ? 'yes' : 'no';
}
else if (input instanceof mw.widgets.
this.mergedFromTemplate[field] = value ?
new Date(value + 'T00:00:00Z').toLocaleDateString('en-GB', {
year: 'numeric', month: 'long', day: 'numeric'
}) : undefined;
if (value.length > 0) {
fieldLayouts[field].setWarnings([]);
Line 8,293 ⟶ 8,288:
placeholder: mw.msg('deputy.ante.mergedTo.to.placeholder')
}),
date: new mw.widgets.
$overlay: this.parent.$overlay,
required: true,
icon: 'calendar',
value: parsedDate ? `${parsedDate.getUTCFullYear()}-${parsedDate.getUTCMonth() + 1}-${parsedDate.getUTCDate()}` : undefined,
}),
small: new OO.ui.CheckboxInputWidget({
Line 8,333 ⟶ 8,327:
this.mergedToTemplate[field] = value ? 'yes' : 'no';
}
else if (input instanceof mw.widgets.
this.mergedToTemplate[field] = value ?
new Date(value + 'T00:00:00Z').toLocaleDateString('en-GB', {
year: 'numeric', month: 'long', day: 'numeric'
}) : undefined;
if (value.length > 0) {
fieldLayouts[field].setWarnings([]);
Line 11,461 ⟶ 11,455:
"deputy.ante.copied.afd.label": "AfD page",
"deputy.ante.copied.afd.help": "The AfD page if the copy was made due to an AfD closed as \"merge\".",
"deputy.ante.copied.date.placeholder": "Date (YYYY-MM-DD)",
"deputy.ante.copied.advanced": "Advanced",
"deputy.ante.copied.dateInvalid": "The previous date value, \"$1\", was not a valid date.",
Line 13,469 ⟶ 13,464:
}
var cteStyles = ".copied-template-editor .oo-ui-window-frame {width: 1000px !important;}.copied-template-editor .oo-ui-menuLayout > .oo-ui-menuLayout-menu {height: 20em;width: 20em;}.copied-template-editor .oo-ui-menuLayout > .oo-ui-menuLayout-content {left: 20em;}.cte-preview .copiednotice {margin-left: 0;margin-right: 0;}.cte-merge-panel {padding: 16px;z-index: 20;border: 1px solid lightgray;margin-bottom: 8px;}.copied-template-editor .oo-ui-bookletLayout-outlinePanel {bottom: 32px;}.cte-actionPanel {height: 32px;width: 100%;position: absolute;bottom: 0;z-index: 1;background-color: white;border-top: 1px solid #c8ccd1;}.cte-actionPanel > .oo-ui-buttonElement {display: inline-block;margin: 0 !important;}.cte-templateOptions {margin: 8px;display: flex;}.cte-templateOptions > * {flex: 1;}.cte-fieldset {border: 1px solid gray;background-color: #ddf7ff;padding: 16px;min-width: 200px;clear: both;}.cte-fieldset-date {float: left;margin-top: 10px !important;}.cte-fieldset-advswitch {float: right;}.cte-fieldset-advswitch .oo-ui-fieldLayout-field,.cte-fieldset-date .oo-ui-fieldLayout-field {display: inline-block !important;}.cte-fieldset-advswitch .oo-ui-fieldLayout-header {display: inline-block !important;margin-right: 16px
/**
|