== Creating a page-list editing widget for the ProofreadPage extension ==
**Phabricator Task:** T172953
**Name:** Sohom Datta
**IRC:** `Sohom_Datta`
**Web Profile:** [Linkedin](https://www.linkedin.com/in/sohom-datta-b41b01193/), [Github](https://github.com/sohomdatta1)
**Location:** India, mainly Kolkata
**Typical working hours (include your timezone):** 8:00 AM to 12:00 PM IST, around ~ 12.5 hours accounting for breaks.
===Deliverables===
* Creating a widget in the ProofreadPage extension using the OOUI library that can deliver the following features:
* An inline non-editable representation of the page-lists as they would appear colour coded in the viewing mode with the links swapped out for buttons.
* An OOUI dialogue window containing a preferably zoomable thumbnail and a set of options to choose ( such as "Number", "Roman", "Advertisement", "-", "Plate" etc with "Number" selected by default ). There will be a field beside the Number and Roman options where one will be able to specify the specific value if any they want to assign that particular page. (Wireframe of the concept I'm thinking of){F31697754}
* A "Switch to Advanced Editing" mode button that replaces the button representation with a `<textarea>` with a preview button to preview content placed in the text area. This will be done in a way similar to that of the current implementation of the license preview in the UploadWizard.
* A fallback for no-javascript users which will be the UI currently being used.
* Adding a feature flag that can be enabled to beta-test the widget while still in development.
* Write documentation on how to use this OOUI widget on www.mediawiki.org.
* Provide continued support and fix bugs related to the widget after the end of the program.
* Write tests (Selenium, QUnit and PHPUnit) for the JavaScript and PHP code (respectively) written during the internship.
===Mockups===
* [Link to mockups](https://drive.google.com/drive/folders/1M8sKZPRg-FMnJPGiSKXfHvUoSehd8E6J?usp=sharing)
===Possible Mentor(s)===
* Sam Wilson and Satdeep Gill
* **Have you contacted your mentors already?** Yes
===Timeline===
* **Community Bonding Period (April 27, 2020 - May 18, 2020):**
* __Week 1__ (April 27 - May 3): I'll familiarize myself with the general workflow of uploading books and creating Index pages for the same using the current UI. I'll also familiarise myself with the codebase of the ProofreadPage extension and how various components of it work together.
* __Week 2__ (May 3 - May 10): Getting Selenium up and running, doing a deep dive into how selenium tests are written and writing preliminary tests for the proofreadpage Index page to get an intuition of the same.
* __Week 3__ (May 10 - May 18): I’ll study and learn about the ResourceLoader modules and take a look at the general JavaScript packaging architecture of Wikimedia and start working on the basic framework for my project. I'll also take a look
* **Coding Period (May 18, 2020 - August 10, 2020):**
* __Week 1__ (May 18 - May 25): Discuss and iron out any questions I may have regarding the implementation of the OOUI widget with my mentor and start with the helper functions and modules required to interact with the PHP backend.
* __Week 2__ (May 25 - June 1): Finish with work on helper functions and modules under the guidance of my mentor. Write bi-weekly report.
*__Week 3__ (June 1 - June 8): TesIron out and check for bugs,y implementation doubts with my mentor. and fix any bugs that can be detectedStudy the code and implementation of similar JavaScript-based OOUI widgets currently in use by the Wikimedia community. Write the bi-weekly report and prepare for evaluation.
* __Week 4__ (June 8 - June 15): Iron out anyStart working on the implementation doubtsof the interface with guidance from my mentors. Study the code and implementation of similar JavaScript-based OOUI widgets currently in use by the Wikimedia communityWrite the bi-weekly report.
* __Evaluation - I__ (June 15 - June 19 (June 22)): Start workingWork on the implementation of the interface with guidance from my mentors. Write the bi-weekly report.
* __Week 1__ (June 22 - June 29) & __Week 2__ (June 29 - July 6): Work on the implementation with guidance from my mentors. Write bi-weekly report.
* __Week 3__ (July 6 - July 13): Finish implemWork on any outstanding bugs (tentation, work on any outstandvely will have exams during bugs.this period)
* __Evaluation - II__ (July 13 - July 17 (July 20)): WorkFinish working on integrating the module into the PHP backend,mplementation, fix any bugs that may be found. test the feature and work on any bugs that may be detectedWrite bi-weekly report.
* __Week 1__ (July 20 - July 27): Write documentation for the feature on www.mediawiki.org with guidance from community members. Write the bi-weekly report.Integrating it with the PHP backend, fixing unexpected bugs.
* __Week 2__ (July 27 - August 1): Write documentation of www.mediawiki.org with guidance from community members
* __Week 2__ & __Week 3__ (July 27 - August 10): I want to keep the last twoone weeks as a buffer to account for spillages and unforeseen delays that may occur during the project.
* **Final Evaluation(August, 10, 2020 - August 17, 2020):**
* Fixing unforeseen bugs, waiting around for final evaluation and working on community feedback.
===Participation===
* I'll be committing my progress to the master branch of the Proofread_Page extension via Gerrit.
* I’ll be fairly active on the `#mediawiki` IRC channel and will be asking any general queries regarding MediaWiki there. I’ll also consult with my mentor via matrix.org/in the phabricator task/on the wiki talk page if I have questions regarding the architecture or implementation of a particular feature.
* I’m reachable during working hours on Phabricator, via my email (`sohom.datta@learner.manipal.edu`) or any of my talk pages on Wikimedia (thanks to email notifications).
* I'll post bi-weekly updates regarding my progress on my MediaWiki user page.
===About Me===
> **Your education (completed or in progress):**
I’m a first-year student pursuing a Bachelors Degree in Computer Science and Engineering at Manipal Institute of Technology. I completed my schooling at St James’ School, Kolkata. I have been studying Computer Science for over four years (since my 9th grade) and am fairly proficient in general coding concepts, including preliminary data structures and algorithms.
> **How did you hear about this program?**
I was first introduced to Google Summer of Code at an event in my college by ACM Manipal where seniors who had already participated in the program talked about their experiences. My acquaintance with the Wikimedia part of the program, however, was purely incidental. It was a result of me feeling a resonance with the concept of the Wikimedia movement and a tiny amount of familiarity that I had gained regarding the Wikimedia movement when one of my classmates in high school pushing me towards contributing to Wikipedia as an IP address.
> **Will you have any other time commitments, such as school work, another job, planned vacation, etc, during the duration of the program?**
Due to the coronavirus situation in India, my college has preponed my summer vacations to 20 March - 1 June from 6 May - 20 July.My college classes will resume from 1st June, I'm confident that even with my classeshowever, I'll still be able to devote > 30 hours ( >5contribute upwards of 30 hours per day ) to thea week towards this project and get it completed in the stipulatedfinish it in time. However,I will also have some exams during the July 6 - July 13 week which may lead to a bit of inactivity during that period. to be on the safe side I am considering starting work on the project early (first week of April) to be in the clear and offset any shortage/constrains of time I may encounter due to the time during which I'll be attending classeI'll be in touch with my mentors and inform them of my progress. I'll be in continous contact with my mentor and keep them informed regarding my progress am also considering starting in early April (two weeks in advance) to offset the time that I may not be able to devote to the project as a result of my classes just to be in the clear.
> **We advise all candidates eligible for Google Summer of Code and Outreachy to apply for both programs. Are you planning to apply to both programs, and if so, with what organization(s)? **
No.
> **What does making this project happen mean to you?**
This project will give me the opportunity to repay back the debt I feel I have incurred from Wikimedia volunteers as a student due to my reliance on Wikipedia for my school projects. Further, the fact that this project has the potential of positively impacting millions of people using this feature and that working on this project will give me the opportunity to grow and bloom as a developer spur me on to complete this project. Also, I do not intend to leave Wikimedia regardless of whether or not this proposal gets accepted for Google Summer of Code, I intend to stay back and keep on contributing and helping out the Wikimedia community by solving technical tasks.
===Past Experience===
==== Wikimedia ====
I have been a part of the Wikimedia community since November 2019. As of March 14, I’ve made 12 contributions (not counting my contributions to the extension mentioned below) to the Wikimedia codebase, 5 of which are still pending review. ([Gerrit profile](https://gerrit.wikimedia.org/r/q/owner:sohom.datta%2540learner.manipal.edu))
* <will put in a list of contributions later...>
Additionally, I’ve submitted patches for two of the microtasks for this project.
* [Fixed missing public function documentation error](https://gerrit.wikimedia.org/r/c/mediawiki/extensions/ProofreadPage/+/574224) (T243932)
* [Added option to remove close button and add icon to PopupWidget head](https://gerrit.wikimedia.org/r/c/oojs/ui/+/578466) (T164958)
I’ve also created (and am the co-maintainer for) a small extension, [ProtectionIndicator](https://gerrit.wikimedia.org/g/mediawiki/extensions/ProtectionIndicator) which adds a small lock icon at the top of each and every protected page and shows a popup giving users an explanation of why and who protected the page. The extension was created by me to gain intuition into the various aspects of ResourceLoader and how each and every component in an extension works with each other.
I am also active on English Wikipedia where I create articles on subjects related to Indian history, contribute to tech-related articles while also fighting vandalism from time to time. ([Wikipedia stats](https://xtools.wmflabs.org/ec/en.wikipedia.org/Sohom%20data))
==== Personal Experience ====
I’m a freshman pursuing my Bachelors in Technology in Computer Science at Manipal Institute of Technology. I have four years of experience with programming having taken Computer Science classes (Java) since my 9th grade and am fairly proficient with the preliminary algorithms and data structures. I have quite a bit of experience with HTML, CSS and vanilla JS having taught myself the basics of frontend web-dev in 11th grade. Additionally, over the course of September - October 2019, I also have taught myself the basics of PHP which I feel has helped me greatly while contributing over the course of February and March.
I’ve also participated in the "task-phase" of Project Manas, a student project in our university that works in areas related to artificial intelligence. This is where I got introduced to open-source technologies such as Git, Linux and Tensorflow and the amazing community surrounding open-source software development.