User:Jeph paul/joinDoc

From Meta, a Wikimedia project coordination wiki

Join is a gadget that is currently under development.

It is meant to help users join a grant proposal along with a short brief on how they would contribute. It is intended to be enabled for all logged in users.

Overview[edit]

Functionality[edit]

The gadget lets a user to join a project from the available set of roles. The user will also have to add a line on how he plans to contribute. The line is added to a section in the page. This section title can be defined in the tool's config file. If the said section is not found a new section is created. The user is also added to the said role in the infobox in the page.

Configuration[edit]

There are two configuration files, Join Interface Messages, which has the interface messages and joinConfig which has the config for the tool.

In the example below one could replace the string the says 'Join' with 'Join this project'. That would then be shown in the tool.

var joinInterfaceMessages = {
	"default":{
		"title":"Join",
		"placeholder-role":"Choose a role",
		"placeholder-comment":"Click here to add comment",
		"button-join":"Join",
		"button-cancel":"Cancel",
		"message-error":"Sorry, there was an error",
		"message-signature":"Your signature will be automatically added to your comment",
		"message-feedback":"Thank you for joining",
		"message-description":"	Tell us how you will help in a sentence or two",
		"roles":{
			"researcher":"Researcher",
			"developer":"Developer",
			"volunteer":"Volunteer",
			"designer":"Designer",
			"advisor":"	Advisor",
			"project_manager":"Project Manager",
			"community_manager":"Community Manager",
		},
	},
};

Custom interface messages for other grant types can be be enabled by copying the above dictionary in full and editing the values to be changed. The key has to be the name of the set of pages in the namespace Grants: Eg: https://meta.wikimedia.org/wiki/Grants:IdeaLab/Build/Tools, here it would be just 'Idealab' or in the case of meta.wikimedia.org/wiki/Grants:IEG, it would be 'IEG'


Lets say the dict looks like

var joinInterfaceMessages = {
	"default":{
		"title":"Join",
		"placeholder-role":"Choose a role",
		"placeholder-comment":"Click here to add comment",
		"button-join":"Join",
		"button-cancel":"Cancel",
		"message-error":"Sorry, there was an error",
		"message-signature":"Your signature will be automatically added to your comment",
		"message-feedback":"Thank you for joining",
		"message-description":"	Tell us how you will help in a sentence or two",
		"roles":{
			"researcher":"Researcher",
			"developer":"Developer",
			"volunteer":"Volunteer",
			"designer":"Designer",
			"advisor":"	Advisor",
			"project_manager":"Project Manager",
			"community_manager":"Community Manager",
		},
	},
};

So now on adding IEG the it would look like

/*<languages />*/
var joinInterfaceMessages = {
	"default":{
		"title":"Join",
		"placeholder-role":"Choose a role",
		"placeholder-comment":"Click here to add comment",
		"button-join":"Join",
		"button-cancel":"Cancel",
		"message-error":"Sorry, there was an error",
		"message-signature":"Your signature will be automatically added to your comment",
		"message-feedback":"Thank you for joining",
		"message-description":"	Tell us how you will help in a sentence or two",
		"roles":{
			"researcher":"Researcher",
			"developer":"Developer",
			"volunteer":"Volunteer",
			"designer":"Designer",
			"advisor":"	Advisor",
			"project_manager":"Project Manager",
			"community_manager":"Community Manager",
		},
	},
	"IEG":{
		"title":"Join",
		"placeholder-role":"Choose a role",
		"placeholder-comment":"Click here to add comment",
		"button-join":"Join",
		"button-cancel":"Cancel",
		"message-error":"Sorry, there was an error",
		"message-signature":"Your signature will be automatically added to your comment",
		"message-feedback":"Thank you for joining",
		"message-description":"	Tell us how you will help in a sentence or two",
		"roles":{
			"researcher":"Researcher",
			"developer":"Developer",
			"volunteer":"Volunteer",
			"designer":"Designer",
			"advisor":"	Advisor",
			"project_manager":"Project Manager",
			"community_manager":"Community Manager",
		},
	},
};

Similarly joinConfig can also be configured. It currently has, the name of the section to which the comment is added & a message

Background[edit]

This tool was built as part of Idealabs April July 2014 sprint