Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update prettier and prettier config #827

Merged
merged 3 commits into from
Jan 30, 2024
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
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/bug.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ about: Something isn't working as expected. 😕

### Versions

* picasso.js: (x.y.z)
* Browser: ?
- picasso.js: (x.y.z)
- Browser: ?

### Additional context

Expand Down
2 changes: 1 addition & 1 deletion examples/hammer/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
Expand Down
2 changes: 1 addition & 1 deletion examples/q-scatterplot/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
Expand Down
2 changes: 1 addition & 1 deletion examples/scatterplot/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"eslint-config-prettier": "9.1.0",
"eslint-plugin-import": "2.29.1",
"eslint-plugin-jsx-a11y": "6.8.0",
"eslint-plugin-prettier": "4.2.1",
"eslint-plugin-prettier": "5.1.3",
"extend": "3.0.2",
"globby": "14.0.0",
"husky": "8.0.3",
Expand All @@ -58,8 +58,8 @@
"jest-puppeteer": "9.0.2",
"jsdom": "23.2.0",
"lerna": "6.6.2",
"prettier": "2.8.8",
"pretty-quick": "3.1.3",
"prettier": "3.2.4",
"pretty-quick": "4.0.0",
"puppeteer": "21.6.1",
"rollup": "2.79.1",
"rollup-plugin-babel": "4.4.0",
Expand Down
28 changes: 14 additions & 14 deletions packages/picasso.js/src/core/component/interpolate-object.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,20 @@ export function value(a, b, k) {
: (t === 'number'
? number
: t === 'string'
? (c = color(b)) && colorKeys.includes(k)
? ((b = c), rgb)
: string
: b instanceof color
? rgb
: b instanceof Date
? date
: isNumberArray(b)
? numberArray
: Array.isArray(b)
? genericArray
: (typeof b.valueOf !== 'function' && typeof b.toString !== 'function') || isNaN(b)
? object
: number)(a, b);
? (c = color(b)) && colorKeys.includes(k)
? ((b = c), rgb)
: string
: b instanceof color
? rgb
: b instanceof Date
? date
: isNumberArray(b)
? numberArray
: Array.isArray(b)
? genericArray
: (typeof b.valueOf !== 'function' && typeof b.toString !== 'function') || isNaN(b)
? object
: number)(a, b);
}

export default function object(a, b) {
Expand Down
8 changes: 4 additions & 4 deletions packages/picasso.js/src/core/data/extractor-matrix.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ function datumExtract(propCfg, cell, { key }) {
typeof propCfg.value === 'function' // eslint-disable-line no-nested-ternary
? propCfg.value(cell)
: typeof propCfg.value !== 'undefined'
? propCfg.value
: cell,
? propCfg.value
: cell,
};

datum.label =
typeof propCfg.label === 'function' // eslint-disable-line no-nested-ternary
? propCfg.label(cell)
: typeof propCfg.label !== 'undefined'
? String(propCfg.label)
: String(datum.value);
? String(propCfg.label)
: String(datum.value);

if (propCfg.field) {
datum.source = {
Expand Down
16 changes: 8 additions & 8 deletions plugins/q/src/data/extractor-s.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,16 @@ function datumExtract(propCfg, cell, { key }) {
typeof propCfg.value === 'function'
? propCfg.value(cell)
: typeof propCfg.value !== 'undefined'
? propCfg.value
: cell, // eslint-disable-line no-nested-ternary
? propCfg.value
: cell, // eslint-disable-line no-nested-ternary
};

datum.label =
typeof propCfg.label === 'function'
? propCfg.label(cell)
: typeof propCfg.label !== 'undefined'
? String(propCfg.label)
: String(datum.value); // eslint-disable-line no-nested-ternary
? String(propCfg.label)
: String(datum.value); // eslint-disable-line no-nested-ternary

if (propCfg.field) {
datum.source = {
Expand Down Expand Up @@ -165,14 +165,14 @@ export default function extract(config, dataset, cache, util) {
typeof p.value === 'function'
? p.value(fieldValues)
: typeof p.value !== 'undefined'
? p.value
: fieldValues,
? p.value
: fieldValues,
label:
typeof p.label === 'function'
? p.label(fieldLabels)
: typeof p.label !== 'undefined'
? String(p.label)
: String(ret[propsArr[l]].value),
? String(p.label)
: String(ret[propsArr[l]].value),
};
}
}
Expand Down
8 changes: 4 additions & 4 deletions plugins/q/src/data/extractor-t.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,16 +126,16 @@ function datumExtract(propCfg, cell, { key }) {
typeof propCfg.value === 'function'
? propCfg.value(cell)
: typeof propCfg.value !== 'undefined'
? propCfg.value
: cell, // eslint-disable-line no-nested-ternary
? propCfg.value
: cell, // eslint-disable-line no-nested-ternary
};

datum.label =
typeof propCfg.label === 'function'
? propCfg.label(cell)
: typeof propCfg.label !== 'undefined'
? String(propCfg.label)
: String(datum.value); // eslint-disable-line no-nested-ternary
? String(propCfg.label)
: String(datum.value); // eslint-disable-line no-nested-ternary

if (propCfg.field) {
datum.source = {
Expand Down
12 changes: 6 additions & 6 deletions studio/src/components/RenderingArea/RenderingArea.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,12 @@ const RenderingArea = ({ title, code, data, api, settings, dataSource }) => {
generator,
})
: [
{
type: 'q',
key: 'qHyperCube',
data: data.box ? data.generated.box.qHyperCube : data.qHyperCube,
},
]) || {};
{
type: 'q',
key: 'qHyperCube',
data: data.box ? data.generated.box.qHyperCube : data.qHyperCube,
},
]) || {};
prevDataScript.current = dataHashId;
prevData.current = theData;
}
Expand Down
2 changes: 1 addition & 1 deletion test/integration/brushing/tap.fix.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<title>Basic bar chart</title>
Expand Down
4 changes: 2 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@

/* Completeness */
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
"skipLibCheck": true /* Skip type checking all .d.ts files. */
"skipLibCheck": true /* Skip type checking all .d.ts files. */,
},
"files": ["packages/picasso.js/types/index.d.ts"]
"files": ["packages/picasso.js/types/index.d.ts"],
}
Loading
Loading