mirror of
https://github.com/qlik-oss/nebula.js.git
synced 2025-12-19 17:58:43 -05:00
chore(ci): add circleci config
This commit is contained in:
82
.circleci/config.yml
Normal file
82
.circleci/config.yml
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
version: 2
|
||||||
|
|
||||||
|
aliases:
|
||||||
|
- &restore_yarn_cache
|
||||||
|
name: Restore yarn cache
|
||||||
|
keys:
|
||||||
|
- yarn-packages-{{ .Branch }}-{{ checksum "yarn.lock" }}
|
||||||
|
- yarn-packages-{{ .Branch }}
|
||||||
|
- yarn-packages-
|
||||||
|
- &save_yarn_cache
|
||||||
|
name: Save yarn cache
|
||||||
|
paths:
|
||||||
|
- ~/.cache/yarn
|
||||||
|
key: yarn-packages-{{ .Branch }}-{{ checksum "yarn.lock" }}
|
||||||
|
- &filter_master
|
||||||
|
branches:
|
||||||
|
only: master
|
||||||
|
- &attach
|
||||||
|
at: ~/project
|
||||||
|
|
||||||
|
defaults: &defaults
|
||||||
|
working_directory: ~/project
|
||||||
|
docker:
|
||||||
|
- image: circleci/node:10.9.0-browsers
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
install:
|
||||||
|
<<: *defaults
|
||||||
|
steps:
|
||||||
|
- checkout
|
||||||
|
- restore_cache: *restore_yarn_cache
|
||||||
|
- run:
|
||||||
|
name: Install packages
|
||||||
|
command: yarn install --frozen-lockfile
|
||||||
|
- save_cache: *save_yarn_cache
|
||||||
|
- persist_to_workspace:
|
||||||
|
root: ~/project
|
||||||
|
paths:
|
||||||
|
- .
|
||||||
|
|
||||||
|
build:
|
||||||
|
<<: *defaults
|
||||||
|
steps:
|
||||||
|
- attach_workspace: *attach
|
||||||
|
- run:
|
||||||
|
name: Build packages
|
||||||
|
command: yarn run build
|
||||||
|
- persist_to_workspace:
|
||||||
|
root: ~/project
|
||||||
|
paths:
|
||||||
|
- packages/*/dist
|
||||||
|
|
||||||
|
lint:
|
||||||
|
<<: *defaults
|
||||||
|
steps:
|
||||||
|
- attach_workspace: *attach
|
||||||
|
- run:
|
||||||
|
name: Lint
|
||||||
|
command: yarn run lint
|
||||||
|
|
||||||
|
test-unit:
|
||||||
|
<<: *defaults
|
||||||
|
steps:
|
||||||
|
- attach_workspace: *attach
|
||||||
|
- run:
|
||||||
|
name: Unit tests
|
||||||
|
command: yarn run test:unit
|
||||||
|
|
||||||
|
workflows:
|
||||||
|
version: 2
|
||||||
|
build-all:
|
||||||
|
jobs:
|
||||||
|
- install
|
||||||
|
- build:
|
||||||
|
requires:
|
||||||
|
- install
|
||||||
|
- test-unit:
|
||||||
|
requires:
|
||||||
|
- build
|
||||||
|
- lint:
|
||||||
|
requires:
|
||||||
|
- build
|
||||||
3
.eslintignore
Normal file
3
.eslintignore
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
**/dist/*
|
||||||
|
**/__test__/unit/coverage/*
|
||||||
|
**/__test__/component/coverage/*
|
||||||
@@ -20,6 +20,30 @@
|
|||||||
"no-plusplus": 0,
|
"no-plusplus": 0,
|
||||||
"no-bitwise" : 0,
|
"no-bitwise" : 0,
|
||||||
"react/destructuring-assignment": [0, "always"],
|
"react/destructuring-assignment": [0, "always"],
|
||||||
"react/prop-types": 0
|
"react/prop-types": 0,
|
||||||
}
|
"react/no-deprecated": 0
|
||||||
|
},
|
||||||
|
"overrides": [
|
||||||
|
{
|
||||||
|
"files": ["**/*.spec.js"],
|
||||||
|
"env": {
|
||||||
|
"browser": false,
|
||||||
|
"node": true,
|
||||||
|
"mocha": true
|
||||||
|
},
|
||||||
|
"globals": {
|
||||||
|
"chai": false,
|
||||||
|
"expect": false,
|
||||||
|
"sinon": false,
|
||||||
|
"page": false
|
||||||
|
},
|
||||||
|
"plugins": [
|
||||||
|
"mocha"
|
||||||
|
],
|
||||||
|
"rules": {
|
||||||
|
"mocha/no-exclusive-tests": "error",
|
||||||
|
"no-unused-expressions": 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ module.exports = {
|
|||||||
['@babel/preset-env', { targets: { node: 'current' } }],
|
['@babel/preset-env', { targets: { node: 'current' } }],
|
||||||
],
|
],
|
||||||
plugins: [
|
plugins: [
|
||||||
'@babel/plugin-transform-react-jsx',
|
['@babel/plugin-transform-react-jsx', { pragma: 'preact.h' }],
|
||||||
[
|
[
|
||||||
'istanbul',
|
'istanbul',
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "cross-env NODE_ENV=production FORCE_COLOR=1 lerna run build --stream",
|
"build": "cross-env NODE_ENV=production FORCE_COLOR=1 lerna run build --stream",
|
||||||
"build:watch": "FORCE_COLOR=1 lerna run build:watch --stream",
|
"build:watch": "FORCE_COLOR=1 lerna run build:watch --stream",
|
||||||
|
"lint": "eslint packages --ext .js --ext .jsx",
|
||||||
"test": "yarn run test:unit",
|
"test": "yarn run test:unit",
|
||||||
"test:unit": "aw -c aw.config.js"
|
"test:unit": "aw -c aw.config.js"
|
||||||
},
|
},
|
||||||
@@ -12,17 +13,19 @@
|
|||||||
"url": "git+https://github.com/qlik-trial/nebula.js.git"
|
"url": "git+https://github.com/qlik-trial/nebula.js.git"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@after-work.js/aw": "^5.1.3",
|
||||||
"@babel/cli": "^7.2.3",
|
"@babel/cli": "^7.2.3",
|
||||||
"@babel/core": "^7.2.2",
|
"@babel/core": "^7.2.2",
|
||||||
"@babel/plugin-transform-react-jsx": "^7.3.0",
|
"@babel/plugin-transform-react-jsx": "^7.3.0",
|
||||||
"@babel/preset-env": "^7.3.1",
|
"@babel/preset-env": "^7.3.1",
|
||||||
"@babel/preset-react": "^7.0.0",
|
"@babel/preset-react": "^7.0.0",
|
||||||
"after-work.js": "^4.3.2",
|
"babel-plugin-istanbul": "^5.1.0",
|
||||||
"cross-env": "^5.2.0",
|
"cross-env": "^5.2.0",
|
||||||
"eslint": "^5.12.1",
|
"eslint": "^5.12.1",
|
||||||
"eslint-config-airbnb": "^17.1.0",
|
"eslint-config-airbnb": "^17.1.0",
|
||||||
"eslint-plugin-import": "^2.15.0",
|
"eslint-plugin-import": "^2.15.0",
|
||||||
"eslint-plugin-jsx-a11y": "^6.2.0",
|
"eslint-plugin-jsx-a11y": "^6.2.0",
|
||||||
|
"eslint-plugin-mocha": "^5.2.1",
|
||||||
"eslint-plugin-react": "^7.12.4",
|
"eslint-plugin-react": "^7.12.4",
|
||||||
"lerna": "^3.10.7",
|
"lerna": "^3.10.7",
|
||||||
"rollup": "^1.1.2",
|
"rollup": "^1.1.2",
|
||||||
|
|||||||
@@ -1,72 +0,0 @@
|
|||||||
.nucleus-selection-toolbar {
|
|
||||||
position: absolute;
|
|
||||||
left: 0;
|
|
||||||
right: 0;
|
|
||||||
top: -48px;
|
|
||||||
padding: 8px;
|
|
||||||
line-height: 24px;
|
|
||||||
box-sizing: border-box;
|
|
||||||
background: white;
|
|
||||||
display: flex;
|
|
||||||
justify-content: flex-end;
|
|
||||||
}
|
|
||||||
.nucleus-selection-toolbar > * {
|
|
||||||
margin-left: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nucleus-cell {
|
|
||||||
position: absolute;
|
|
||||||
top: 0px;
|
|
||||||
left: 0px;
|
|
||||||
bottom: 0px;
|
|
||||||
right: 0px;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
font-size: 14px;
|
|
||||||
line-height: 16px;
|
|
||||||
color: #404040;
|
|
||||||
font-family: "Source Sans Pro", Arial, "sans-serif";
|
|
||||||
}
|
|
||||||
.nucleus-cell .nucleus-cell__header {
|
|
||||||
flex: 0 0 auto;
|
|
||||||
padding: 8px;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
.nucleus-cell .nucleus-cell__footnote {
|
|
||||||
flex: 0 0 auto;
|
|
||||||
padding: 8px;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
.nucleus-cell .nucleus-content {
|
|
||||||
flex: 1 0 auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nucleus-cell__error {
|
|
||||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAGCAYAAADgzO9IAAAAM0lEQVQYV2P8z8BgzMjAcJYBCUDFkIUYGECCIBFGdJVQwbNwCSSVYGPBEuiCYAlsgiAJANbwDGtj7MYdAAAAAElFTkSuQmCC);
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nucleus-content {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
.nucleus-content .nucleus-content__body {
|
|
||||||
position: absolute;
|
|
||||||
top: 8px;
|
|
||||||
left: 8px;
|
|
||||||
bottom: 8px;
|
|
||||||
right: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nucleus-type--s {
|
|
||||||
font-size: 12px;
|
|
||||||
line-height: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nucleus-type--m {
|
|
||||||
font-size: 16px;
|
|
||||||
line-height: 20px;
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user