Revert "This maintenance script really belongs in the client, not in lib."

I disagree that it belongs in the client. This script allows polling for changes in the changes table, which is defined in lib. Wikibase Client is just one extension making use of it, but you can just as well have it run for some other extension or tool.

This reverts commit 570a74f6a5ac7b73c3e610c2a45713204cd1a881
Merge "Revert "This maintenance script really belongs in the client, not in lib.""
refactored Site QUnit tests

Change-Id: Icbf011c49fd8f60439a91aee7b77e402bca10372
(Bug #40563) Rebuilding the store on the client when repo is rebuilt.
Call lib/maintenance/rebuildAllData.php on client installation.

Change-Id: Ieffa844bbc871345a9daf87f25a1f3496d7c385e
Display disabled button for site-links 'add' if site-links are full (non-JS)

patchset 2: rebased & resolved conflicts

Change-Id: I27249f54fdb41eddb3f651ebe2bcd5d68ff4c0ee
refactored wikibase.js tests

Change-Id: I83c248c98881941ad8ff771b00f0c33a7484acda
Added removeDuplicates method to Statements and Claims interfaces

Change-Id: I04d83cec130c86dc3396de10d8a22ba65b3d5eb2
Fixed failing QUnit tests after Id0cb4088 got merged early

The main problem was that if wb.ui.Toolbar.Label.stateChangeable is false, some of the state handling didn't work logically anymore. This has been fixed now. Another bug which was detected while fixing this is that empty toolbars always returned disabled as state. This has been changed to return enabled (which isn't much better, either the state should be remembered or we should re-thing the state system).

Change-Id: If6545d9b24a415c1d3da1cb72ba1e8dda568dff7
PropertyEditTool.isFull() will now return false if multiple values allowed

This was set to true before but overwritten in SiteLinksEditTool. Now this allows an infinite number of values instead of zero.

Change-Id: Id8c1ed1c079337f70d473232636b18834e9192df
Further re-factored PropertyEditTool tests

* Introduced a factory for creating new test PropertyEditTool instances, startup is no longer abused to create three instances.
* Added a function for the test addValueToPET() to add values to the PropertyEditTool. See the todo though.
* Corrected logic of PropertyEditTool.isFull() in case multiple values were not allowed.

Change-Id: If7fff87b416cf91b08e4557a88b5b3d50caa0add
Merge "Added removeDuplicates method to Statements and Claims interfaces"
Merge "(Bug #40563) Rebuilding the store on the client when repo is rebuilt. Call lib/maintenance/rebuildAllData.php on client installation."
Merge "Fixed failing QUnit tests after Id0cb4088 got merged early"
Merge "PropertyEditTool.isFull() will now return false if multiple values allowed"
Merge "Further re-factored PropertyEditTool tests"
css re-arrangements for no-JS edit links

Change-Id: Ia99d71101bd1e2f1d5f4e9cae06ebbb94d596b0c
Added tests for StateExtension

Also changed StateExtension.prototype.setState() to always pass all arguments to abstract _setState() function

Change-Id: I11f70fdd9d989ac2db6a835697198d4cf914e392
Renamed StateExtension to StatableObject

This is kind of a follow-up to I05070669, where wb.ui.StateExtension was renamed to wb.utilities.ui.StateExtension already. StatableObject should be more descriptive and goes in one line with our other 'extensions' (extension is not really a nice term here).

Change-Id: I89a84e1de31092dd2d14f5303290b922e44c3ad3
placeholders for empty label/description in no-JS version

* patch set 2: Remove 'wb-value-empty' classes and empty nodes for JS to initialize properly.

Change-Id: Id381fb312840517205c12c34d8815ba407b60f42
correct styling of add alias button in no-JS version

Change-Id: Iae00e0ecbe1c30a2eb524b5760ec7be5c6395564