Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Commit d0f25b1

Browse files
author
Jeremy Wiebe
committed
Merge branch 'develop' into npm-auto-publish
2 parents 7c95384 + c006c6d commit d0f25b1

7 files changed

Lines changed: 35 additions & 11 deletions

File tree

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,19 @@
11
## To be released
2+
3+
## v2.7.4 (February 2, 2017)
4+
- Add new classname prefixes to CSS documentation: `pw-` and `qa-`
5+
- Add links to alternative CSSComb text editor plugins
6+
- Fix `lint-md` to work properly on Node.js v6+
7+
8+
## v2.7.3
9+
- Temporarily disable `spaced-comment` errors, until Astro release builds comply
10+
with this rule.
11+
12+
## v2.7.2
13+
- Temporarily downgrade `spaced-comment` errors to warning level, until Astro
14+
release builds comply with this rule.
15+
16+
## v2.7.1
217
- Re-organized and cleaned up markdown linting files
318
- Switched to using `no-duplicate-headings-in-section` (instead of
419
`no-duplicate-headings`)

css/class-naming-conventions/readme.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,8 @@ Prefix | Purpose | Location |
286286
`.c-` | Component classes: this includes the root component (typically the class that defines the component itself), sub-component class, and the modifier class. [See above](#component-oriented-naming) | Project's component directory |
287287
`.t-` | Template classes: These class names are declared as the `template` in the corresponding [view](https://mobify.atlassian.net/wiki/display/PLAT/Views). Example template classes include: `.t-pdp`, `.t-home`, `.t-category`. | Project's template directory |
288288
`.u-` | Utility classes: these are meant as one-off, strongly opinionated, high specificity overrides for very narrowly defined styles. | Project's `/styles/utilities` directory |
289+
`.pw-` | Progressive Web classes: these classes are reserved as styling hooks for React components built into Mobify's [Progressive Web SDK](https://github.com/mobify/progressive-web-sdk) | These classes are located either in the SDK component's source directory in the SDK, or in a Project's theme directory. |
290+
`.qa-` | QA classes: these classes are reserved for, and used as selector hooks for tests (unit tests, integration tests, etc.). These classes are **not meant as styling hooks**, so no CSS should be applied to any `qa-` classes! | In a project's test directories. |
289291
`.x-` | Classes that start with `x-` are considered global states or document states. That means these classes should only be applied to the `html` or `body` element. Example states include `x-ios`, `x-portrait`, `x-retina`, `x-header-is-sticky`, etc. | *varies* |
290292
`.m-` (*) | Desktop embedded mobile markup classes: these are classes that we will use if we author Markup that is intended for clients to embed onto their desktop pages, but is for mobile content. | *n/a* |
291293
`.js-` | Javascript classes are used exclusively by scripts and should never have CSS styles applied to them. Repeat: **Do NOT** style Javascript classes. | *n/a*

css/csscomb/readme.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,9 @@ Before you start, make sure you have [Package Control](https://packagecontrol.io
3434
(Find your local path by running `npm config get prefix` and append `/lib/node_modules/mobify-code-style/css/.csscomb.json` to the result)
3535
1. Restart Sublime
3636
1. Start combing your Sass!
37+
38+
### Other Text Editors
39+
40+
* [CSSComb for VIM](https://github.com/csscomb/vim-csscomb)
41+
* [jetbrains-csscomb](https://github.com/csscomb/jetbrains-csscomb) which should work for all JetBrains IDEs, such as IDEA, PyCharm, WebStorm, PhpStorm, RubyMine, and perhaps others.
42+
* [CSSComb for Emacs](https://github.com/channikhabra/css-comb.el), including Aquamacs

docs/bin/lint-md

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,16 @@ done
1414
DOCS_DIR="$(cd "$(dirname "$BIN")/.." && pwd)"
1515
REMARK_RC="$DOCS_DIR/remarkrc"
1616

17-
# This is tricky. `remark` is a dep of mobify-code-style
18-
# and so won't show up in `node_modules/.bin` of a project
19-
# that uses mobify-code-style. We have to move into the
20-
# the mobify-code-style /docs directory and find the npm
21-
# bin directory relative that _that_ to find remark!
22-
REMARK_CLI="$(cd "$DOCS_DIR" && npm bin)/remark"
17+
if [[ $(node -v) =~ ^v[0-4] ]]; then
18+
# Node v4!!
19+
# This is tricky. `remark` is a dep of mobify-code-style
20+
# and so won't show up in `node_modules/.bin` of a project
21+
# that uses mobify-code-style. We have to move into the
22+
# the mobify-code-style /docs directory and find the npm
23+
# bin directory relative that _that_ to find remark!
24+
REMARK_CLI="$(cd "$DOCS_DIR" && npm bin)/remark"
25+
else
26+
REMARK_CLI="$(npm bin)/remark"
27+
fi
2328

2429
$REMARK_CLI --rc-path $REMARK_RC "$@"

es5/mobify-es5.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ rules:
4646
- never
4747
space-infix-ops: error
4848
space-unary-ops: error
49-
spaced-comment: error
5049
no-undef: error
5150
eol-last: warn
5251
quotes:

javascript/.eslintrc

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,6 @@
8484
// Disallow spacing around non-word unary operators: -, +, --, ++, !, !!
8585
"space-unary-ops": [2, { "words": true, "nonwords": false }],
8686

87-
// Enforce whitespace after the start of a comment (// or /*)
88-
"spaced-comment": 2,
89-
9087
// Disallow undeclared variables (unless mentioned in /*global ...*/ comment)
9188
"no-undef": 2,
9289

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "mobify-code-style",
3-
"version": "2.7.0",
3+
"version": "2.7.4",
44
"description": "Code style guide and linting tools for Mobify",
55
"repository": {
66
"type": "git",

0 commit comments

Comments
 (0)