Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["prettier-plugin-jsdoc"],
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["prettier-plugin-jsdoc"],
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"lint-fix": "yarn run lint-fix-js && yarn run lint-fix-css"
},
"devDependencies": {
"@homer0/prettier-plugin-jsdoc": "__VERSION__",
"eslint": "__VERSION__",
"eslint-config-airbnb-base": "__VERSION__",
"eslint-config-prettier": "__VERSION__",
Expand All @@ -25,7 +26,6 @@
"eslint-plugin-prettier": "__VERSION__",
"eslint-plugin-yml": "__VERSION__",
"prettier": "__VERSION__",
"prettier-plugin-jsdoc": "__VERSION__",
"stylelint": "__VERSION__",
"stylelint-config-standard": "__VERSION__",
"stylelint-order": "__VERSION__"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
/**
* Counter block functionality.
*
* @param {HTMLElement} context Context element to search for counter
* blocks.
* @param {HTMLElement} context Context element to search for counter
* blocks.
*/
initCounterBlock(context) {
const counterBlocks = context.querySelectorAll('[data-sw-base-counter]');
Expand Down Expand Up @@ -74,12 +74,22 @@
/**
* Remove updated class after a delay for visual feedback.
*
* @param {HTMLElement} element The element to remove the class from.
* @param {HTMLElement} element The element to remove the class from.
*/
removeUpdatedClassAfterDelay(element) {
setTimeout(function removeUpdatedClass() {
element.classList.remove('updated');
}, 300);
},

/**
* Get the current counter value from localStorage.
*
* @return {number} The current counter value, or 0 if not set.
*/
getCounterValue() {
const storageKey = 'ys_counter_value';
return parseInt(localStorage.getItem(storageKey), 10) || 0;
},
};
})(Drupal);
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/**/*
*.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"printWidth": 80,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
"options": {
"parser": "css",
"printWidth": 10000,
"singleQuote": false
}
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
* @file Global theme behaviors.
* @param $
* @param Drupal
* @global Drupal, jQuery
* @global Drupal, JQuery.
*/

/**
* Global theme behaviors.
*
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
*/
(function StarWarsBehaviors($, Drupal) {
Drupal.behaviors.star_wars = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"private": true,
"description": "NodeJS dependencies for star wars project",
"devDependencies": {
"@homer0/prettier-plugin-jsdoc": "__VERSION__",
"autoprefixer": "__VERSION__",
"chokidar-cli": "__VERSION__",
"eslint": "__VERSION__",
Expand All @@ -18,7 +19,6 @@
"postcss": "__VERSION__",
"postcss-cli": "__VERSION__",
"prettier": "__VERSION__",
"prettier-plugin-jsdoc": "__VERSION__",
"sass": "__VERSION__",
"stylelint": "__VERSION__",
"stylelint-config-standard": "__VERSION__",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
/**
* Counter block functionality.
*
* @param {HTMLElement} context Context element to search for counter
* blocks.
* @param {HTMLElement} context Context element to search for counter
* blocks.
*/
initCounterBlock(context) {
const counterBlocks = context.querySelectorAll('[data-sw-base-counter]');
Expand Down Expand Up @@ -74,12 +74,22 @@
/**
* Remove updated class after a delay for visual feedback.
*
* @param {HTMLElement} element The element to remove the class from.
* @param {HTMLElement} element The element to remove the class from.
*/
removeUpdatedClassAfterDelay(element) {
setTimeout(function removeUpdatedClass() {
element.classList.remove('updated');
}, 300);
},

/**
* Get the current counter value from localStorage.
*
* @return {number} The current counter value, or 0 if not set.
*/
getCounterValue() {
const storageKey = 'ys_counter_value';
return parseInt(localStorage.getItem(storageKey), 10) || 0;
},
};
})(Drupal);
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/**/*
*.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"printWidth": 80,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
"options": {
"parser": "css",
"printWidth": 10000,
"singleQuote": false
}
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
* @file Global theme behaviors.
* @param $
* @param Drupal
* @global Drupal, jQuery
* @global Drupal, JQuery.
*/

/**
* Global theme behaviors.
*
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
*/
(function StarWarsBehaviors($, Drupal) {
Drupal.behaviors.star_wars = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"private": true,
"description": "NodeJS dependencies for star wars project",
"devDependencies": {
"@homer0/prettier-plugin-jsdoc": "__VERSION__",
"autoprefixer": "__VERSION__",
"chokidar-cli": "__VERSION__",
"eslint": "__VERSION__",
Expand All @@ -18,7 +19,6 @@
"postcss": "__VERSION__",
"postcss-cli": "__VERSION__",
"prettier": "__VERSION__",
"prettier-plugin-jsdoc": "__VERSION__",
"sass": "__VERSION__",
"stylelint": "__VERSION__",
"stylelint-config-standard": "__VERSION__",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
/**
* Counter block functionality.
*
* @param {HTMLElement} context Context element to search for counter
* blocks.
* @param {HTMLElement} context Context element to search for counter
* blocks.
*/
initCounterBlock(context) {
const counterBlocks = context.querySelectorAll('[data-sw-base-counter]');
Expand Down Expand Up @@ -74,12 +74,22 @@
/**
* Remove updated class after a delay for visual feedback.
*
* @param {HTMLElement} element The element to remove the class from.
* @param {HTMLElement} element The element to remove the class from.
*/
removeUpdatedClassAfterDelay(element) {
setTimeout(function removeUpdatedClass() {
element.classList.remove('updated');
}, 300);
},

/**
* Get the current counter value from localStorage.
*
* @return {number} The current counter value, or 0 if not set.
*/
getCounterValue() {
const storageKey = 'ys_counter_value';
return parseInt(localStorage.getItem(storageKey), 10) || 0;
},
};
})(Drupal);
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/**/*
*.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"printWidth": 80,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
"options": {
"parser": "css",
"printWidth": 10000,
"singleQuote": false
}
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
* @file Global theme behaviors.
* @param $
* @param Drupal
* @global Drupal, jQuery
* @global Drupal, JQuery.
*/

/**
* Global theme behaviors.
*
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
*/
(function StarWarsBehaviors($, Drupal) {
Drupal.behaviors.star_wars = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"private": true,
"description": "NodeJS dependencies for star wars project",
"devDependencies": {
"@homer0/prettier-plugin-jsdoc": "__VERSION__",
"autoprefixer": "__VERSION__",
"chokidar-cli": "__VERSION__",
"eslint": "__VERSION__",
Expand All @@ -18,7 +19,6 @@
"postcss": "__VERSION__",
"postcss-cli": "__VERSION__",
"prettier": "__VERSION__",
"prettier-plugin-jsdoc": "__VERSION__",
"sass": "__VERSION__",
"stylelint": "__VERSION__",
"stylelint-config-standard": "__VERSION__",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
/**
* Counter block functionality.
*
* @param {HTMLElement} context Context element to search for counter
* blocks.
* @param {HTMLElement} context Context element to search for counter
* blocks.
*/
initCounterBlock(context) {
const counterBlocks = context.querySelectorAll('[data-the-force-base-counter]');
Expand Down Expand Up @@ -74,12 +74,22 @@
/**
* Remove updated class after a delay for visual feedback.
*
* @param {HTMLElement} element The element to remove the class from.
* @param {HTMLElement} element The element to remove the class from.
*/
removeUpdatedClassAfterDelay(element) {
setTimeout(function removeUpdatedClass() {
element.classList.remove('updated');
}, 300);
},

/**
* Get the current counter value from localStorage.
*
* @return {number} The current counter value, or 0 if not set.
*/
getCounterValue() {
const storageKey = 'ys_counter_value';
return parseInt(localStorage.getItem(storageKey), 10) || 0;
},
};
})(Drupal);
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/**/*
*.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"printWidth": 80,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"plugins": ["@homer0/prettier-plugin-jsdoc"],
"jsdocReplaceTagsSynonyms": false,
"overrides": [
{
"files": ["*.css"],
"options": {
"parser": "css",
"printWidth": 10000,
"singleQuote": false
}
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
* @file Global theme behaviors.
* @param $
* @param Drupal
* @global Drupal, jQuery
* @global Drupal, JQuery.
*/

/**
* Global theme behaviors.
*
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
* @param {jQuery} $ The jQuery object.
* @param {Drupal} Drupal The Drupal object.
*/
(function LightsaberBehaviors($, Drupal) {
Drupal.behaviors.lightsaber = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"private": true,
"description": "NodeJS dependencies for New hope project",
"devDependencies": {
"@homer0/prettier-plugin-jsdoc": "__VERSION__",
"autoprefixer": "__VERSION__",
"chokidar-cli": "__VERSION__",
"eslint": "__VERSION__",
Expand All @@ -18,7 +19,6 @@
"postcss": "__VERSION__",
"postcss-cli": "__VERSION__",
"prettier": "__VERSION__",
"prettier-plugin-jsdoc": "__VERSION__",
"sass": "__VERSION__",
"stylelint": "__VERSION__",
"stylelint-config-standard": "__VERSION__",
Expand Down
Loading