Skip to content

Commit

Permalink
refactor: updated even further dependencies (pattern-lab#1320)
Browse files Browse the repository at this point in the history
* chore(docs): some typos

missed to replace mustache initially and incorrect handlebars two times (both in package name and URL)

* Revert "Merge pull request #2 from pattern-lab/dev"

This reverts commit 7812878, reversing
changes made to 26db979.

* Revert "Merge pull request #1 from pattern-lab/dev"

This reverts commit 26db979, reversing
changes made to fc90750.

* Revert "chore(docs): some typos"

This reverts commit 271dc8d.

* refactor: updated dependency ejs

* refactor: updated dependency scroll-js

* refactor: updated dependency classnames

* refactor: updated dependency gulp

* refactor: replaced dependency opn by its new name open

* refactor: updated dependency lerna

and executed a simple migration script as stated in https://github.com/lerna/lerna/blob/main/CHANGELOG.md#400-2021-02-10

* refactor: updated dependency @auto-it/released

* refactor: updated dependency auto

* refactor: updated dependency fs-extra

* refactor: updated dependency better-opn

* refactor: updated dependency cosmiconfig

* fix(cosmiconfig-update): corrected the variable name

* fix(cosmiconfig-update): added the variable name

* refactor: updated dependency fuse.js

* refactor: updated dependency deepmerge

* refactor: updated dependency execa

* refactor: updated dependency js-yaml

* refactor: updated dependency jsdoc-to-markdown

* refactor: updated dependency archiver

* refactor: updated dependency has-yarn

* refactor: updated dependency inquirer

* refactor: updated dependency ora

* refactor: updated dependency http-auth

and added necessary new dependency http-auth-connect that provides a method that got extracted from the original one.

* refactor(node): aligned all node versions within the packages

* refactor: updated dependency node-sass

* refactor: updated dependency open

* refactor: updated dependency yargs

* refactor: updated dependency @11ty/eleventy-plugin-syntaxhighlight

* refactor: updated dependency markdown-it

* build: regenerated yarn.lock file

* refactor: updated dependency node-sass pattern-lab#1320

* refactor: updated dependency recursive-copy

* chore: reverted node-sass dependency update

* refactor: rebuild yarn.lock file

* refactor(node): aligned all node versions within the packages

* build: regenerated yarn.lock file

* refactor: updated dependency husky

* refactor: updated dependency @11ty/eleventy

* chore: code optimizations

that are mentioned by the github pipeline as well

* chore: rebuild yarn.lock file

* chore: some reformatting

* chore: rebuild yarn.lock file

* chore: reformatted

* chore: reverted commit a852046

* Revert "chore: reformatted"

This reverts commit 1531399.

* chore: formatting

* chore: formatting

* chore: formatting

* chore: formatting

This reverts commit 271dc8d.

* chore: formatting

* chore: formatting

* build: regenerated package-lock.json

* refactor: revert commit 373ea94 and 9b60cf2

* chore: reformatting

* fix: corrected those files contents

* refactor: updated dependency send

* refactor: updated dependency commander

* refactor: we need to fix this dependencies version range to minor

* build: regenerated yarn.lock file

Co-authored-by: Maximilian <[email protected]>
  • Loading branch information
mfranzke and Maximilian authored Jan 29, 2022
1 parent 515df95 commit b6f18e0
Show file tree
Hide file tree
Showing 24 changed files with 1,109 additions and 889 deletions.
1 change: 0 additions & 1 deletion .husky/.gitignore

This file was deleted.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
]
},
"dependencies": {
"@auto-it/released": "^9.40.5",
"@auto-it/released": "^10.27.0",
"@babel/plugin-proposal-decorators": "^7.13.5",
"@babel/plugin-syntax-jsx": "^7.12.13",
"auto": "^9.40.5",
"auto": "^10.27.0",
"babel-eslint": "^10.0.2",
"eslint": "^6.1.0",
"eslint-config-prettier": "^6.0.0",
Expand Down Expand Up @@ -51,6 +51,6 @@
]
},
"devDependencies": {
"husky": "^6.0.0"
"husky": "^7.0.4"
}
}
18 changes: 9 additions & 9 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@
},
"dependencies": {
"@pattern-lab/core": "^5.15.5",
"archiver": "2.1.1",
"archiver": "5.3.0",
"chalk": "4.1.0",
"commander": "2.15.1",
"deepmerge": "^2.1.1",
"execa": "4.0.3",
"fs-extra": "6.0.1",
"commander": "6.2.1",
"deepmerge": "^4.2.2",
"execa": "5.0.0",
"fs-extra": "10.0.0",
"glob": "7.1.6",
"has-yarn": "1.0.0",
"inquirer": "5.1.0",
"has-yarn": "2.1.0",
"inquirer": "8.0.0",
"lodash": "4.17.21",
"ora": "2.1.0"
"ora": "5.4.0"
},
"devDependencies": {
"@pattern-lab/starterkit-mustache-base": "3.0.3",
Expand All @@ -47,7 +47,7 @@
],
"scripts": {
"lint": "eslint ./{bin,test}",
"test:separate": "tap ./test/*.test.js --reporter spec --timeout=120",
"test:separate": "tap './test/*.test.js' --reporter spec --timeout=120",
"prepublish": "npx dos2unix-cli bin/patternlab.js"
},
"repository": "https://github.com/pattern-lab/patternlab-node/tree/master/packages/cli",
Expand Down
8 changes: 4 additions & 4 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
"chalk": "4.1.0",
"chokidar": "3.5.1",
"dive": "0.5.0",
"fs-extra": "5.0.0",
"fs-extra": "10.0.0",
"glob": "7.1.6",
"graphlib": "2.1.8",
"js-beautify": "1.13.5",
"js-yaml": "3.13.1",
"js-yaml": "4.1.0",
"lodash": "4.17.21",
"markdown-it": "6.0.1",
"markdown-it": "12.0.6",
"node-fetch": "2.6.1",
"recursive-copy": "2.0.13",
"update-notifier": "5.1.0"
Expand All @@ -28,7 +28,7 @@
"eslint": "^6.1.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-prettier": "^3.1.0",
"jsdoc-to-markdown": "5.0.1",
"jsdoc-to-markdown": "6.0.1",
"prettier": "^2.2.1",
"rewire": "2.5.2",
"standard-version": "9.1.1",
Expand Down
6 changes: 2 additions & 4 deletions packages/core/src/lib/data_loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@ function loadFile(dataFilePath, fsDep) {

if (dataFile && fsDep.existsSync(path.resolve(dataFile))) {
try {
return yaml.safeLoad(
fsDep.readFileSync(path.resolve(dataFile), 'utf8')
);
return yaml.load(fsDep.readFileSync(path.resolve(dataFile), 'utf8'));
} catch (err) {
throw new Error(`Error loading file: ${dataFile} - ${err.message}`);
}
Expand Down Expand Up @@ -55,7 +53,7 @@ function loadDataFromFolder(dataFilesPath, excludeFileNames, fsDep) {

dataFiles.forEach(function (filePath) {
try {
const jsonData = yaml.safeLoad(
const jsonData = yaml.load(
fsDep.readFileSync(path.resolve(filePath), 'utf8')
);
mergeObject = _.merge(mergeObject, jsonData);
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/lib/markdown_parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const markdown_parser = function () {
if (chunks && chunks[1]) {
//parse the yaml if we got it
const frontmatter = chunks[1];
returnObject = yaml.safeLoad(frontmatter);
returnObject = yaml.load(frontmatter);
}

if (chunks[2]) {
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/lib/pseudopattern_hunter.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ pseudopattern_hunter.prototype.find_pseudopatterns = function (
paths.source.patterns,
pseudoPatterns[i]
);
variantFileData = yaml.safeLoad(
variantFileData = yaml.load(
fs.readFileSync(variantFileFullPath, 'utf8')
);
} catch (err) {
Expand Down
2 changes: 1 addition & 1 deletion packages/development-edition-engine-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"@pattern-lab/engine-mustache": "^5.15.1",
"@pattern-lab/engine-react": "^5.15.1",
"@pattern-lab/uikit-workshop": "^5.15.7",
"gulp": "3.9.1",
"gulp": "4.0.2",
"minimist": "^1.2.5",
"react": "16.2.0"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/edition-node-gulp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"@pattern-lab/core": "^5.15.5",
"@pattern-lab/engine-mustache": "^5.15.1",
"@pattern-lab/uikit-workshop": "^5.15.7",
"gulp": "3.9.1",
"gulp": "4.0.2",
"minimist": "1.2.5"
},
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-handlebars/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "5.15.1",
"main": "lib/engine_handlebars.js",
"dependencies": {
"fs-extra": "^8.1.0",
"fs-extra": "^10.0.0",
"glob": "^7.1.6",
"handlebars": "^4.7.7"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-liquid/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "5.15.1",
"main": "lib/engine_liquid.js",
"dependencies": {
"fs-extra": "5.0.0",
"fs-extra": "10.0.0",
"liquidjs": "2.2.0"
},
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-mustache/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "5.15.1",
"main": "lib/engine_mustache.js",
"dependencies": {
"fs-extra": "0.30.0",
"fs-extra": "10.0.0",
"mustache": "3.1.0"
},
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-nunjucks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"deprecated": false,
"description": "The nunjucks PatternEngine for Pattern Lab / Node",
"dependencies": {
"fs-extra": "7.0.0",
"fs-extra": "10.0.0",
"nunjucks": "^3.2.3"
},
"engines": {
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-twig-php/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"@basalt/twig-renderer": "^2.0.0",
"@pattern-lab/core": "^5.15.5",
"chalk": "^4.1.0",
"fs-extra": "0.30.0"
"fs-extra": "10.0.0"
},
"keywords": [
"Pattern Lab",
Expand Down
3 changes: 2 additions & 1 deletion packages/engine-twig/lib/engine_twig.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,8 @@ var engine_twig = {
engineFileExtension: '.twig',

// regexes, stored here so they're only compiled once
findPartialsRE: /{%[-]?\s*(?:extends|include|embed|from|import|use)\s+('[^']+'|"[^"]+").*?%}/g,
findPartialsRE:
/{%[-]?\s*(?:extends|include|embed|from|import|use)\s+('[^']+'|"[^"]+").*?%}/g,
findPartialKeyRE: /"((?:\\.|[^"\\])*)"/,
findListItemsRE:
/({{#( )?)(list(I|i)tems.)(one|two|three|four|five|six|seven|eight|nine|ten|eleven|twelve|thirteen|fourteen|fifteen|sixteen|seventeen|eighteen|nineteen|twenty)( )?}}/g, // TODO
Expand Down
2 changes: 1 addition & 1 deletion packages/engine-twig/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "5.15.3",
"main": "lib/engine_twig.js",
"dependencies": {
"fs-extra": "0.30.0",
"fs-extra": "10.0.0",
"twing": "^5.0.2"
},
"keywords": [
Expand Down
6 changes: 3 additions & 3 deletions packages/live-server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const path = require('path');
const url = require('url');
const http = require('http');
const send = require('send');
const open = require('opn');
const open = require('open');
const es = require('event-stream');
const os = require('os');
const chokidar = require('chokidar');
Expand Down Expand Up @@ -370,14 +370,14 @@ LiveServer.start = function (options) {
if (openPath !== null)
if (typeof openPath === 'object') {
openPath.forEach((p) =>
open(openURL + p, { app: browser }).catch(() =>
open(openURL + p, { app: { name: browser } }).catch(() =>
console.log(
'Warning: Could not open pattern lab in default browser.'
)
)
);
} else {
open(openURL + openPath, { app: browser }).catch(() =>
open(openURL + openPath, { app: { name: browser } }).catch(() =>
console.log('Warning: Could not open pattern lab in default browser.')
);
}
Expand Down
4 changes: 2 additions & 2 deletions packages/live-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
"http-auth-connect": "^1.0.5",
"morgan": "1.10.0",
"object-assign": "4.1.1",
"opn": "5.3.0",
"open": "8.0.9",
"proxy-middleware": "0.15.0",
"send": "0.16.2",
"send": "0.17.2",
"serve-index": "1.9.1"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-tab/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "",
"main": "index.js",
"dependencies": {
"fs-extra": "0.30.0",
"fs-extra": "10.0.0",
"glob": "7.1.6",
"lodash": "4.17.21"
},
Expand Down
14 changes: 7 additions & 7 deletions packages/uikit-workshop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,19 +50,19 @@
"@webcomponents/custom-elements": "^1.4.3",
"autoprefixer": "^9.6.5",
"babel-loader": "^8.0.6",
"better-opn": "^1.0.0",
"better-opn": "^3.0.0",
"browser-sync": "^2.26.7",
"classnames": "^2.2.6",
"classnames": "^2.3.1",
"clean-css-loader": "^1.0.1",
"clean-webpack-plugin": "0.1.19",
"clipboard": "^2.0.8",
"copy-webpack-plugin": "^5.0.2",
"cosmiconfig": "^5.0.6",
"cosmiconfig": "^7.0.0",
"css-loader": "^3.2.0",
"ejs": "^2.7.2",
"ejs": "^3.1.6",
"express": "^4.17.1",
"fg-loadjs": "^1.1.0",
"fuse.js": "^3.4.5",
"fuse.js": "^6.4.6",
"hard-source-webpack-plugin-patch": "^0.13.3",
"hasha": "^5.2.2",
"hogan.js": "^3.0.2",
Expand Down Expand Up @@ -90,7 +90,7 @@
"sass": "1.43.4",
"sass-loader": "^10.1.1",
"scriptjs": "^2.5.9",
"scroll-js": "^2.2.0",
"scroll-js": "3.4.x",
"skatejs": "^5.2.4",
"style-loader": "^1.0.0",
"svg-sprite-loader": "^4.1.6",
Expand All @@ -104,7 +104,7 @@
"webpack-merge": "^4.2.2",
"webpackbar": "^4.0.0",
"wolfy87-eventemitter": "^5.2.9",
"yargs": "^16.2.0"
"yargs": "^17.0.1"
},
"browserslist": [
"last 2 version",
Expand Down
5 changes: 1 addition & 4 deletions packages/uikit-workshop/src/html/partials/base-template.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@
{{# descBlockExists }}

<div
class="
pl-c-pattern-info__panel pl-c-pattern-info__panel--info
pl-js-pattern-info
"
class="pl-c-pattern-info__panel pl-c-pattern-info__panel--info pl-js-pattern-info"
>
{{# isPatternView }}
<!-- extra info for modal view -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,11 +145,9 @@ class Search extends BaseComponent {
const fuseOptions = {
shouldSort: true,
threshold: 0.3,
tokenize: true,
includeMatches: true,
location: 0,
distance: 100,
maxPatternLength: 32,
minMatchCharLength: 1,
keys: ['label'],
};
Expand Down
8 changes: 4 additions & 4 deletions packages/uikit-workshop/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ const argv = require('yargs').argv;
const merge = require('webpack-merge');
const WebpackBar = require('webpackbar');

const cosmiconfig = require('cosmiconfig');
const explorer = cosmiconfig('patternlab');
const cosmiconfigSync = require('cosmiconfig').cosmiconfigSync;
const explorerSync = cosmiconfigSync('patternlab');

// @todo: wire these two ocnfigs up to use cosmicconfig!
const defaultConfig = {
Expand All @@ -33,9 +33,9 @@ module.exports = function (apiConfig) {
let configToSearchFor;

if (argv.patternlabrc) {
configToSearchFor = await explorer.loadSync(argv.patternlabrc);
configToSearchFor = await explorerSync.load(argv.patternlabrc);
} else {
configToSearchFor = await explorer.searchSync();
configToSearchFor = await explorerSync.search();
}

if (configToSearchFor) {
Expand Down
Loading

0 comments on commit b6f18e0

Please sign in to comment.