User:DR/test.js: Difference between revisions
From Test Wiki
Content deleted Content added
No edit summary Tag: Reverted |
No edit summary Tag: Reverted |
||
| Line 4: | Line 4: | ||
$('#firstHeading').text('MassDelete'); |
$('#firstHeading').text('MassDelete'); |
||
var |
var categoryInputField = new OO.ui.TextInputWidget({ |
||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
pagesTextarea = new OO.ui.MultilineTextInputWidget({ |
|||
placeholder: 'Enter list of pages (one per line)', |
placeholder: 'Enter list of pages (one per line)', |
||
autosize: true, |
autosize: true, |
||
rows: 10 |
rows: 10, |
||
style: 'margin-top: 10px;' |
|||
}), |
}), |
||
reasonInputField = new OO.ui.TextInputWidget({ |
reasonInputField = new OO.ui.TextInputWidget({ |
||
placeholder: 'Reason for deletion' |
placeholder: 'Reason for deletion', |
||
style: 'margin-top: 10px;' |
|||
}), |
}), |
||
deleteTalkPagesCheckbox = new OO.ui.CheckboxInputWidget({ |
deleteTalkPagesCheckbox = new OO.ui.CheckboxInputWidget({ |
||
selected: false |
selected: false |
||
| ⚫ | |||
categoryInputField = new OO.ui.TextInputWidget({ |
|||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
}), |
}), |
||
previewButton = new OO.ui.ButtonWidget({ |
previewButton = new OO.ui.ButtonWidget({ |
||
label: 'Preview Deletion', |
label: 'Preview Deletion', |
||
flags: ['primary'] |
flags: ['primary'], |
||
style: 'margin-top: 10px;' |
|||
}), |
}), |
||
startButton = new OO.ui.ButtonWidget({ |
startButton = new OO.ui.ButtonWidget({ |
||
| Line 31: | Line 34: | ||
icon: 'alert', |
icon: 'alert', |
||
flags: ['primary', 'progressive'], |
flags: ['primary', 'progressive'], |
||
disabled: true |
disabled: true, |
||
style: 'margin-top: 10px;' |
|||
}), |
}), |
||
cancelButton = new OO.ui.ButtonWidget({ |
cancelButton = new OO.ui.ButtonWidget({ |
||
label: 'Cancel', |
label: 'Cancel', |
||
flags: ['primary', 'destructive'], |
flags: ['primary', 'destructive'], |
||
href: 'https:' + mw.config.get('wgServer') |
href: 'https:' + mw.config.get('wgServer'), |
||
style: 'margin-top: 10px;' |
|||
}), |
}), |
||
logContainer = $("<div>").hide(); |
logContainer = $("<div>").hide(); |
||
var labels = { |
var labels = { |
||
| ⚫ | |||
pagesLabel: $('<p>').text('Pages to Delete:').css('font-weight', 'bold'), |
pagesLabel: $('<p>').text('Pages to Delete:').css('font-weight', 'bold'), |
||
reasonLabel: $('<p>').text('Reason:').css('font-weight', 'bold'), |
reasonLabel: $('<p>').text('Reason:').css('font-weight', 'bold'), |
||
deleteTalkPagesLabel: $('<p>').text('Delete associated talk pages').css('font-weight', 'bold') |
deleteTalkPagesLabel: $('<p>').text('Delete associated talk pages').css('font-weight', 'bold') |
||
| ⚫ | |||
}; |
}; |
||
$('#mw-content-text').append( |
$('#mw-content-text').append( |
||
| ⚫ | |||
labels.pagesLabel, pagesTextarea.$element, |
labels.pagesLabel, pagesTextarea.$element, |
||
labels.reasonLabel, reasonInputField.$element, |
labels.reasonLabel, reasonInputField.$element, |
||
labels.deleteTalkPagesLabel, deleteTalkPagesCheckbox.$element, |
labels.deleteTalkPagesLabel, deleteTalkPagesCheckbox.$element, |
||
| ⚫ | |||
fetchCategoryButton.$element, |
|||
'<br/>', |
'<br/>', |
||
previewButton.$element, |
previewButton.$element, |
||