Skip to content
This repository was archived by the owner on Jun 26, 2018. It is now read-only.

Release 5.6.0 #548

Merged
merged 35 commits into from
Aug 23, 2017
Merged
Show file tree
Hide file tree
Changes from 34 commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
cefcdc3
Merge branch 'dev' into Release6.0.0
Jun 1, 2017
7eded84
Merge branch 'dev' into Release6.0.0
Jun 1, 2017
da20428
DP-3527/DP-3528 - Unused Patterns (#455)
Jun 1, 2017
7ad383c
Bump release to 6.0
jesconstantine Jun 12, 2017
176cb7b
Merge branch 'dev' into Release6.0.0
Jul 3, 2017
1e9a2af
bad merge
Jul 3, 2017
e1ba8d0
ignoring url config file for Release 6.0
Jul 3, 2017
62805cb
Removing disco mode from Pattern Lab.
Jul 6, 2017
5c8f20d
Switch Mayflower over to the Drupal Pattern Lab fork (#488)
sghoweri Jul 12, 2017
a6c7b41
DP-4046 - Hosting from a Subfolder (#503)
Jul 17, 2017
006ce07
Subfolders - changing default domain url to be ""
Jul 18, 2017
dcc325a
Trigger Browser Sync reload after Pattern Lab build (#506)
EvanLovely Jul 17, 2017
25707a6
Adding minor delay to browsersync
Jul 17, 2017
dd0c96e
DP-4048 Establish format for pattern docs (#515)
Jul 21, 2017
90e8b6d
Mapped Locations - Fixing bug with assigning the colored background
Jul 24, 2017
7c25917
DP-4080 - Versioning Documentation (#504)
Jul 26, 2017
d5e2b3f
DP-4053 create + document manual build + deploy process (#530)
Aug 2, 2017
6bf6d06
Workaround to address unexpected Pattern Lab Psuedo-Pattern Data Inhe…
sghoweri Aug 7, 2017
873535a
DP-4176 Service page documentation (#521)
Aug 10, 2017
4277134
DP-4178 / DP-4177 How To page (#523)
Aug 10, 2017
426466e
Merge branch 'master' into C4-Docs
Aug 10, 2017
901b30f
Reverting DP-3527 and 3528 due to breaking changes
Aug 10, 2017
93a31ec
DP-4178 / DP-4177 Guide Page (#524)
Aug 14, 2017
8044bbf
Remove phing deploy step that edits env.js asset paths for drupal (#544)
Aug 15, 2017
48c25e8
DP-4181 Document the contribution process for issues, feature request…
Aug 15, 2017
a54a859
DP-4178 Location page (#527)
Aug 18, 2017
fdd4a5f
DP-4178 topic page (#529)
Aug 18, 2017
80d3073
DP-4178 event page (#533)
Aug 18, 2017
a27b623
DP-4174 document the release process (#531)
Aug 18, 2017
b807ab7
git cherry-pick 35acb7a2
jesconstantine Aug 20, 2017
ab57c3d
Release 5.6 - Event Template - reverting changes to twig blocks.
Aug 22, 2017
0abdbb0
Fix typo to 'brewing' (#549)
meghandavis Aug 21, 2017
9c22d12
Update release notes
jesconstantine Aug 22, 2017
c48e898
Bump version on home page
jesconstantine Aug 22, 2017
6887478
Fix typo in release notes.
jesconstantine Aug 23, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
233 changes: 233 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,233 @@
# Contributing to Mayflower

Thanks for contributing to Mayflower! Please take a minute to review the process outlined in this document to ensure that contribution is easy and effective for everyone involved.

**On this page:**
1. [Using the issue tracker](#using-the-issue-tracker)
1. [Issue Labels](#issue-labels)
1. [Bug Reports](#bug-reports)
1. [Feature Requests](#feature-requests)
1. [Submitting Pull Requests](#submitting-pull-requests)
1. [Getting started](#getting-started)
1. [Get Set Up](#get-set-up)
1. [Forking the repo](#forking-the-repo)
1. [Cloning the repo](#cloning-the-repo)
1. [Installing project dependencies](#installing-project-dependencies)
1. [Keeping in sync](#keeping-in-sync)
1. [Submitting your work](#submitting-your-work)
1. [Spinning up a branch](#spinning-up-a-branch)
1. [Working with Pattern Lab](#working-with-pattern-lab)
1. [Committing your work](#committing-your-work)
1. [Pushing your branch](#pushing-your-branch)
1. [Deploying your work](#deploying-your-work)
1. [Creating a Pull Request](#creating-a-pull-request)
1. [Review by Maintainers](#review-by-maintainers)

## Using the issue tracker
The [issue tracker](https://github.com/massgov/mayflower/issues) is the preferred channel for [bug reports](#bug-reports), [features requests](#feature-requests) and [submitting pull requests](submitting-pull-requests).

### Issue Labels
We use labels to help identify and organize issues. Here's what they represent and how we use them:

- `browser bug` - Issues that are reported to us that are the result of a browser-specific bug. These are diagnosed with reduced test cases and result in an issue opened on that browser's own bug tracker.
- `confirmed` - Issues that have been confirmed with a reduced test case and identify a bug in Mayflower.
- `css` - Issues stemming from our compiled CSS or source Sass files.
- `docs` - Issues for improving or updating our documentation.
- `examples` - Issues involving the example patterns (i.e. content or data) included on our site.
- `feature` - Issues asking for a new feature to be added, or an existing one to be extended or modified.
- `build` - Issues with our build system, which is used to run all our tests, concatenate and compile source files, and more.
- `PRs welcome` - Issues we need or would love help from the community to resolve.
- `js` - Issues stemming from our compiled or source JavaScript files.
- `meta` - Issues with the project itself or our GitHub repository.

## Bug Reports
A bug is a _demonstrable problem_ that is caused by the code in the repository. Good bug reports are extremely helpful, so thanks!

Guidelines for bug reports:

1. **Use the GitHub issue search** — check if the issue has already been
reported.

2. **Check if the issue has been fixed** — try to reproduce it using the
latest `master` or `dev` branch in the repository.

3. **Isolate the problem** — ideally create a [reduced test
case](https://css-tricks.com/reduced-test-cases/) and a live example.

A good bug report shouldn't leave others needing to chase you up for more information. Please try to be as detailed as possible in your report. What is your environment? What steps will reproduce the issue? What browser(s) and OS experience the problem? Do other browsers show the bug differently? What would you expect to be the outcome? All these details will help people to fix any potential bugs.

Example:

> Short and descriptive example bug report title
>
> The browser/OS environment and Mayflower Version in which it occurs.

> Expected behavior - what you would expect to happen on the page / site.

> Existing behavior - what is currently happen on the page / site.

> If suitable, include the steps required to reproduce the bug.
>
> 1. This is the first step
> 2. This is the second step
> 3. Further steps, etc.
>
> `<url>` - a link to the reduced test case
>
> Any other information you want to share that is relevant to the issue being reported. This might include the lines of code that you have identified as causing the bug, and potential solutions (and your opinions on their merits).

## Feature requests

Feature requests are welcome. But take a moment to find out whether your idea fits with the scope and aims of the project. It's up to *you* to make a strong case to convince the project's designers and developers of the merits of this feature. Please provide as much detail and context as possible.

## Pull Requests

Good pull requests—patches, improvements, new features—are a fantastic help!

**Please ask first** before embarking on any significant pull request (e.g. implementing features, refactoring code, porting to a different language), otherwise you risk spending a lot of time working on something that the project's developers might not want to merge into the project.

### Work in source directories
You can modify these files in order to resolve issues and add new features:
- Styles: [`/styleguide/source/assets/scss/`](https://github.com/massgov/mayflower/tree/master/styleguide/source/assets/scss)
- Javascript functionality: [`/styleguide/source/assets/js/`](https://github.com/massgov/mayflower/tree/master/styleguide/source/assets/js)
- Pattern markup, documentation, and data: [`/styleguide/source/_patterns`](https://github.com/massgov/mayflower/tree/master/styleguide/source/_patterns)

**Please do not edit the `gh-pages` branch.** That branch is generated and used to deploy work for testing.

### Getting Started

#### Get set up

In order to run Mayflower locally, you need to have some things installed and set up on your machine. See [setting up your machine](../docs/machine-setup.md).

#### Forking the repo

A fork is a *copy* of a repository. Forking a repository allows you to freely experiment with changes without affecting the original project. Learn more about forking repositories on [Github Help](https://help.github.com/articles/fork-a-repo/).

1. Visit the [Mayflower repo on Github](https://github.com/massgov/mayflower)
1. Click the "Fork" icon in the upper right of the page
1. This will create a fork of the project under your user account which you can browse to at: `https://github.com/<your-github-username>/mayflower`

#### Cloning the repo
Right now, you have a fork of the Mayflower repository, but you don't have the files in that repository on your computer. Let's create a clone of your fork locally on your computer.

1. `git clone git@github.com:<your github username>/mayflower.git`
1. Or, if you don't have [ssh set up on your local environment or with github](https://help.github.com/articles/connecting-to-github-with-ssh/), navigate to your fork of the Mayflower repository at `https://github.com/<your-github-username>/mayflower`.
1. Follow from Step 2 of [Github Help: Cloning a repository](https://help.github.com/articles/cloning-a-repository/).
1. You now have a local representation of *your* Mayflower! Change directory into the repo root: `cd mayflower`

#### Installing project dependencies

1. Move into the styleguide directory `cd styleguide`
1. Generate pattern lab default files `php core/console --generate`
1. Install npm dependencies `npm install`

#### Keeping in sync

In order to make it easy to keep your fork in sync with the original (`massgov/mayflower`), add the original as a remote:

```
git remote add upstream git@github.com:massgov/mayflower.git
```

If you check your remotes (`git remote -v`), you can now see that you have two "remotes" that your local repo is pointed towards: `origin`, which points to *your* Mayflower fork, and `upstream`, which points to `massgov/mayflower`.

### Submitting your work

#### Creating a branch

Any new features and non-emergency bugfixes should branch from the `dev` branch. Hot fixes (production bug fixes) should be branched from the latest release `tag` in the `master` branch.

Make sure your local branch (`dev` for features, `master` for prod bugs) is up-to-date with the `upstream` repo (`massgov/mayflower`).

If you just forked it, you're probably all set. But if there have been a lot of changes to `massgov/mayflower` since you forked it, yours might be out of sync. Here's how to get yours in sync:

```
git checkout dev
git fetch upstream
git merge upstream/dev
git push origin dev
```

Now you can create your new branch:

```
git checkout -b my-issue-number-feature-name
```

If you were working on ticket DP-1234-create-backto-link, then you would type:

```
git checkout -b DP-1234-create-backto-link
```

#### Working with Pattern Lab

Serve Mayflower locally and as you save your changes, it will update automatically:

1. Read the [Pattern Lab docs](http://patternlab.io/docs/index.html)!
1. Run `gulp` from the `/styleguide` directory.
1. Browse to [http://localhost:3000/](http://localhost:3000/) (or port shown in gulp output if you've configured it differently)
1. Familiarize yourself with Mayflower:
- You can use the menu to look at whole page layouts (pages), templates, components (organisms and molecules), child elements (molecules and atoms), and some nuts and bolts (base).
- You can emulate different device sizes by using the size buttons at the top right of the menu bar (S M L FULL RANDOM DISCO).
- You can learn about patterns by clicking the top right COG icon, then selecting "Show Pattern Info" from the drop down.
1. All work is done in the `/styleguide/source` directory.
- Most patterns will have a `.twig` [markup file](https://twig.sensiolabs.org/), `.json` default [data file](http://patternlab.io/docs/data-pattern-specific.html), and `.md` [documentation file](http://patternlab.io/docs/pattern-documenting.html) in the `/styleguide/source/_patterns` directory.
- If a pattern has styles associated with it, the corresponding `.scss` files can be found in the `/styleguide/source/assets/scss` directory. We use [SMACSS](https://smacss.com/book/categorizing) to organize and [BEM](http://getbem.com/introduction/) to structure our [scss](http://sass-lang.com/guide) which gets compiled to css during build and automatically with the `gulp` task running.
- If a pattern has js functionality associated with it, the corresponding [ES6 module](https://hacks.mozilla.org/2015/08/es6-in-depth-modules/) `.js` file can be found in the `/styleguide/source/assets/js/modules` directory.
1. These assets will automatically recompile and the browser will refresh as you save changes.

##### Other notes

* It is helpful to have 2 terminal tabs open when working on this project: one to manage `gulp` tasks and the other to manage `git`. From the tab running `gulp`, type `CTRL` + `C` to kill that task when you're done.
* `gulp` will build the Pattern Lab static assets and generate a static site in the `/styleguide/public` directory. See `/styleguide/tools/gulp/gulp-readme.md`.
* Pattern Lab specific files are in the `/styleguide/public/styleguide` directory (the `styleguide.html` file is automatically generated when twig templates are updated).

#### Committing your work

Make your changes and commit them. Ensure that you only commit the thing you're working on. Make sure that you commit in logical blocks.

Chris Beam explains [How to Write a Git Commit Message](https://chris.beams.io/posts/git-commit/):
> ... a well-crafted Git commit message is the best way to communicate context about a change to fellow developers (and indeed to their future selves). A diff will tell you *what* changed, but only the commit message can properly tell you *why*.

We also love the model Git commit message in Tim Pope's [A Note About Git Commit Messages](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html).

#### Pushing your branch
In order to create a Pull Request (PR) where maintainers can review your work, you first need to push your branch to the `origin` remote (i.e. your Mayflower fork).

To push a new branch up to your fork:

```
git push -u origin DP-1234-create-backto-link
```

This will create the branch on your Mayflower fork. The `-u` flag links this branch with the remote one, so that in the future, you can simply type `git push origin`.

#### Deploying your work

Once your work is complete, deploy your branch to your Mayflower fork's Github Pages, so that its functionality can be tested and reviewed by someone who doesn't have Mayflower running locally. See [our deployment docs](../docs/deploy.md#developer-deployment) for step by step instructions.

#### Creating a Pull Request
Pull requests (PRs) let you tell others about changes you've pushed to a repository on GitHub. Once a pull request is opened, you can discuss and review the potential changes with collaborators and add follow-up commits before the changes are merged into the repository.

1. Follow the steps on [Github Help: Creating a pull request from a fork](https://help.github.com/articles/creating-a-pull-request-from-a-fork/).
- Make sure that the "base fork" points to `massgov/mayflower` and that "base" (branch) points to `dev` for features, `master` for production bug fixes.
- For your PR title, please use: `TICKET Description of ticket`, i.e. `DP-1234 Add back-to button on Announcement template`. Follow the PR template for the rest of the information. Keep in mind:
- Anyone could be reading this Pull Request, so the content and tone may inform people other than those taking part, now or later.
- Be explicit about what feedback you want, if any: a quick pair of eyes on the code, discussion on the technical approach, critique on design, a review of copy.
- Be explicit about when you want feedback, if the Pull Request is work in progress, say so. A prefix of “[WIP]” in the title is a simple, common pattern to indicate that state.
- @mention individuals that you specifically want to involve in the discussion, and mention why. (“/cc @jesconstantine for clarification on this logic”)
- @mention teams that you want to involve in the discussion, and mention why. (“/cc @github/security, any concerns with this approach?”)

#### Review by Maintainers

Once you've opened your PR, Mayflower maintainers will review and either request changes or merge it.

Thanks again!

***

## Acknowledgements

Thanks to the [Twitter Bootstrap](https://github.com/twbs/bootstrap) for having great contribution guidelines, and also to Rob Allen's [The beginner's guide to contributing to a GitHub project](https://akrabat.com/the-beginners-guide-to-contributing-to-a-github-project/) and Matt Stauffer's [How to contribute to an open-source GitHub project using your own fork](https://mattstauffer.co/blog/how-to-contribute-to-an-open-source-github-project-using-your-own-fork) for providing helpful instructions on working with Github open source projects.
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Before opening an issue:

- [Search for duplicate or closed issues](https://github.com/massgov/mayflower/issues?utf8=%E2%9C%93&q=is%3Aissue)
- Read the [contributing guidelines](https://github.com/massgov/mayflower/blob/master/CONTRIBUTING.md)

When reporting a bug, include:

- Mayflower version
- Operating system and version (Windows, Mac OS X, Android, iOS, Win10 Mobile)
- Browser and version (Chrome, Firefox, Safari, IE, MS Edge, Opera 15+, Android Browser)
- Description (write a sentence or two about the issue)
- Steps to reproduce on live site
- Prepare a [reduced test case](https://css-tricks.com/reduced-test-cases/)

When suggesting a feature, include:

- As much detail as possible for what we should add and why it's important to Mayflower
- Relevant links to prior art, screenshots, or live demos whenever possible

35 changes: 35 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<!-- Please use TICKET Description of ticket as PR title (i.e. DP-1234 Add back-to link on Announcement template) -->

## Description
<!-- A few sentences describing the overall goals of the pull request's commits.-->

## Related Issue / Ticket

- [JIRA issue]()
- [Github issue]()

## Steps to Test
<!-- Outline the steps to test or reproduce the PR here. Whenever possible deploy your branch to your fork Github Pages so UAT can be done without rebuilding. See: https://github.com/massgov/mayflower/blob/master/docs/deploy.md -->

1.

## Screenshots
Use something like [licecap](http://www.cockos.com/licecap/) to capture gifs to demonstrate behaviors.


## Additional Notes:

Anything else to add?

#### Impacted Areas in Application
<!-- List general components of the application that this PR will affect: -->

*

#### @TODO
<!-- List any known remaining work for this ticket / issue. -->

*

#### Today I learned...
<!-- Did you learn anything valuable in your work for this PR that you could share with the team? You could list any relevant blogs, docs, or stack overflow posts that helped you with this work. -->
Loading