[MediaWiki-commits] [Gerrit] Add flag collection button and confirm overlay - change (mediawiki...Gather)

2015-04-22 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add flag collection button and confirm overlay
..


Add flag collection button and confirm overlay

Added flag icon to collection when not watchlist or
** collection owner
Added CollectionFlagOverlay for flag confirmation
Added SchemaGatherFlags

bug: T94871
Change-Id: I2b373e5415f76f85dba78d246b3c22af2284c261
---
M i18n/en.json
M i18n/qqq.json
M includes/Gather.hooks.php
M includes/views/Collection.php
M resources/Resources.php
A resources/ext.gather.collection.flag/CollectionFlagOverlay.js
A resources/ext.gather.icons/flag.svg
A resources/ext.gather.logging/SchemaGatherFlags.js
M resources/ext.gather.special/init.js
M resources/ext.gather.styles/collections.less
10 files changed, 179 insertions(+), 7 deletions(-)

Approvals:
  Jdlrobson: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/i18n/en.json b/i18n/en.json
index e0b1ed1..5f2c401 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -48,6 +48,10 @@
gather-delete-collection-delete-label: Delete,
gather-delete-collection-success: Collection was successfully 
deleted.,
gather-delete-collection-failed-error: There was a problem deleting 
this collection.,
+   gather-flag-collection-heading: Flag collection,
+   gather-flag-collection-confirm: Are you sure you want to flag this 
collection for review?,
+   gather-flag-collection-flag-label: Flag,
+   gather-flag-collection-success: Collection was successfully 
flagged.,
gather-confirmation-cancel-button-label: Cancel,
gather-error-unknown-collection: Cannot find the requested 
collection to edit.,
gather-collection-member: Is member of collection.,
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 8b2adf0..b47ece7 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -48,10 +48,14 @@
gather-edit-collection-failed-error: There was a problem saving the 
changes.,
gather-edit-collection-clear-label: Label for button that clears 
search.\n{{Identical|Clear}},
gather-delete-collection-confirm: Text under the heading asking the 
user if they would like to delete a collection.,
-   gather-delete-collection-heading: Heading for collection delete 
overlay,
-   gather-delete-collection-delete-label: Label for delete button in 
delete overlay.\n{{Identical|Delete}},
+   gather-delete-collection-heading: Heading for collection delete 
confirmation overlay,
+   gather-delete-collection-delete-label: Label for delete button in 
delete confirmation overlay.\n{{Identical|Delete}},
gather-delete-collection-success: Toast message indicating that 
deletion was successful.,
gather-delete-collection-failed-error: Toast error indicating there 
was a problem deleting the collection.,
+   gather-flag-collection-heading: Heading text for collection flag 
conirmation overlay,
+   gather-flag-collection-confirm: Text under the heading asking the 
user if they would like to flag a collection for review.,
+   gather-flag-collection-flag-label: Label for flag button in flag 
collection confirmation overlay.,
+   gather-flag-collection-success: Toast message indicating that 
flagging the collection was successful.,
gather-confirmation-cancel-button-label: Label for cancel button in 
confirmation overlay.\n{{Identical|Cancel}},
gather-error-unknown-collection: Error message test when you try to 
edit a collection you do not own or that does not exist.,
gather-collection-member: Alternative text displayed next to 
collection name when page is a member.,
diff --git a/includes/Gather.hooks.php b/includes/Gather.hooks.php
index b9d394a..351f04c 100644
--- a/includes/Gather.hooks.php
+++ b/includes/Gather.hooks.php
@@ -126,8 +126,9 @@
public static function onEventLoggingRegisterSchemas( $schemas ) {
$schemas += array(
'GatherClicks' = 11770314,
+   'GatherFlags' = 11793295,
);
-   self::registerSchemas( array( 'schema.GatherClicks' ) );
+   self::registerSchemas( array( 'schema.GatherClicks', 
'schema.GatherFlags' ) );
return true;
}
 
diff --git a/includes/views/Collection.php b/includes/views/Collection.php
index e5fb7bd..46a2ef5 100644
--- a/includes/views/Collection.php
+++ b/includes/views/Collection.php
@@ -52,7 +52,8 @@
$privacyMsg = wfMessage( 'gather-private' )-plain();
}
 
-   $html = Html::openElement( 'div', array( 'class' = 
'collection-header' ) ) .
+   $html = Html::element( 'div', array( 'class' = 
'collection-moderation' ) ) .
+   Html::openElement( 'div', array( 'class' = 
'collection-header' ) ) .
Html::openElement( 'div', array( 'class' = 
'collection-meta' ) );

[MediaWiki-commits] [Gerrit] Add flag collection button and confirm overlay - change (mediawiki...Gather)

2015-04-16 Thread Robmoen (Code Review)
Robmoen has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/204611

Change subject: Add flag collection button and confirm overlay
..

Add flag collection button and confirm overlay

Added flag icon to collection when not watchlist or
** collection owner
Added CollectionFlagOverlay for flag confirmation
Added SchemaGatherFlags
NEEDS:
* Review
* Schema logging tested
* userGroups is currently an empty string
bug: T94871

Change-Id: I2b373e5415f76f85dba78d246b3c22af2284c261
---
M i18n/en.json
M i18n/qqq.json
M includes/Gather.hooks.php
M includes/views/Collection.php
A resources/ext.gather.collection.flag/CollectionFlagOverlay.js
A resources/ext.gather.collection.flag/content.hogan
A resources/ext.gather.collection.flag/flagOverlay.less
A resources/ext.gather.icons/flag.svg
A resources/ext.gather.logging/SchemaGatherFlags.js
M resources/ext.gather.special/init.js
M resources/ext.gather.styles/collections.less
11 files changed, 179 insertions(+), 17 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather 
refs/changes/11/204611/1

diff --git a/i18n/en.json b/i18n/en.json
index 567ead9..b974dce 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -40,9 +40,13 @@
gather-delete-collection-confirm: Are you sure you want to delete 
this collection?,
gather-delete-collection-heading: Delete collection,
gather-delete-collection-delete-label: Delete,
-   gather-delete-collection-cancel-label: Cancel,
gather-delete-collection-success: Collection was successfully 
deleted.,
gather-delete-collection-failed-error: There was a problem deleting 
this collection.,
+   gather-flag-collection-heading: Flag collection,
+   gather-flag-collection-confirm: Are you sure you want to flag this 
collection for review?,
+   gather-flag-collection-flag-label: Flag,
+   gather-flag-collection-success: Collection was successfully 
flagged.,
+   gather-confirmation-cancel-button-label: Cancel,
gather-error-unknown-collection: Cannot find the requested 
collection to edit.,
gather-collection-member: Is member of collection.,
gather-collection-non-member: Is not member of collection.,
diff --git a/i18n/qqq.json b/i18n/qqq.json
index d7a66ff..1d1c9b4 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -43,11 +43,15 @@
gather-edit-collection-save-label: Label for save button in 
collection editor.\n{{Identical|Done}},
gather-edit-collection-failed-error: There was a problem saving the 
changes.,
gather-delete-collection-confirm: Text under the heading asking the 
user if they would like to delete a collection.,
-   gather-delete-collection-heading: Heading for collection delete 
overlay,
-   gather-delete-collection-delete-label: Label for delete button in 
delete overlay.\n{{Identical|Delete}},
-   gather-delete-collection-cancel-label: Label for cancel button in 
delete overlay.\n{{Identical|Cancel}},
+   gather-delete-collection-heading: Heading for collection delete 
confirmation overlay,
+   gather-delete-collection-delete-label: Label for delete button in 
delete confirmation overlay.\n{{Identical|Delete}},
gather-delete-collection-success: Toast message indicating that 
deletion was successful.,
gather-delete-collection-failed-error: Toast error indicating there 
was a problem deleting the collection.,
+   gather-flag-collection-heading: Heading text for collection flag 
conirmation overlay,
+   gather-flag-collection-confirm: Text under the heading asking the 
user if they would like to flag a collection for review.,
+   gather-flag-collection-flag-label: Label for flag button in flag 
collection confirmation overlay.,
+   gather-flag-collection-success: Toast message indicating that 
flagging the collection was successful.,
+   gather-confirmation-cancel-button-label: Label for cancel button in 
confirmation overlay.\n{{Identical|Cancel}},
gather-error-unknown-collection: Error message test when you try to 
edit a collection you do not own or that does not exist.,
gather-collection-member: Alternative text displayed next to 
collection name when page is a member.,
gather-collection-non-member: Alternative text displayed next to 
collection name when page is not a member.,
diff --git a/includes/Gather.hooks.php b/includes/Gather.hooks.php
index 119e5cb..5351ff1 100644
--- a/includes/Gather.hooks.php
+++ b/includes/Gather.hooks.php
@@ -62,8 +62,9 @@
public static function onEventLoggingRegisterSchemas( $schemas ) {
$schemas += array(
'GatherClicks' = 11770314,
+   'GatherFlags' = 11793295,
);
-   self::registerSchemas( array( 'schema.GatherClicks' ) );
+   self::registerSchemas( array( 'schema.GatherClicks', 
'schema.GatherFlags'