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

getComponentFromError when running Jest in webstorm #1439

Closed
jogelin opened this issue Jun 3, 2019 · 16 comments
Closed

getComponentFromError when running Jest in webstorm #1439

jogelin opened this issue Jun 3, 2019 · 16 comments
Labels

Comments

@jogelin
Copy link
Contributor

jogelin commented Jun 3, 2019

Ticket to provide the solution for people that meet the issue when running jest tests by using @nrwl/builders:jest + webstorm.

Tests are running well by using ng test but don't run when using webstorm + jest:

TypeError: Cannot read property 'getComponentFromError' of null

    at TestBedViewEngine._initIfNeeded (/home/user/dev/packages/core/testing/src/test_bed.ts:393:46)
    at TestBedViewEngine.get (/home/user/dev/packages/core/testing/src/test_bed.ts:473:10)
    at Function.TestBedViewEngine.get (/home/user/dev/packages/core/testing/src/test_bed.ts:243:36)
    at Object.get (/home/user/dev/company/project/node_modules/@netbasal/spectator/bundles/ng:/@netbasal/spectator/lib/service.ts:56:22)
    at Object.<anonymous> (/home/user/dev/company/project/apps/sot-desktop/src/app/features/station-note/station-plan.state.service.spec.ts:16:39)
    at Object.asyncJestLifecycle (/home/user/dev/company/project/node_modules/jest-jasmine2/build/jasmineAsyncInstall.js:53:37)
    at resolve (/home/user/dev/company/project/node_modules/jest-jasmine2/build/queueRunner.js:43:12)
    at new Promise (<anonymous>)
    at mapper (/home/user/dev/company/project/node_modules/jest-jasmine2/build/queueRunner.js:26:19)
    at promise.then (/home/user/dev/company/project/node_modules/jest-jasmine2/build/queueRunner.js:73:41)
    at process.internalTickCallback (internal/process/next_tick.js:77:7)

This issue is related to #862 and #747

Libraries:

  • @angular: 7.1.15
  • @nrwl: 7.8.6
  • @netbasal/spectator: 3.9.1
  • jest: 24.8.0
  • jest-preset-angular: 7.1.1
  • ts-jest: 24.0.2
@jogelin
Copy link
Contributor Author

jogelin commented Jun 3, 2019

The only config that I had to add in my apps/app-name/jest.config.js is setupFilesAfterEnv:

module.exports = {
  name: 'app-name',
  preset: '../../jest.config.js',
  coverageDirectory: '../../coverage/apps/sot/',
  snapshotSerializers: [
    'jest-preset-angular/AngularSnapshotSerializer.js',
    'jest-preset-angular/HTMLCommentSerializer.js'
  ],
  // just add this line
  setupFilesAfterEnv: ["<rootDir>/src/test-setup.ts"],
};

@jogelin jogelin closed this as completed Jun 3, 2019
@lmame
Copy link

lmame commented Jul 20, 2019

@jogelin , thanks a lot, it solved my issue for Services, pipes etc...
Though for Component I have some strange errors.
It seems something is trying to load the component html template using http://localhost/.html

I am trying to tackle this through astTransformers but I was wondering if maybe you had already a workaround for this?

@ronnyek
Copy link

ronnyek commented Jul 24, 2019

I too am running into this same problem...
Error: Uncaught (in promise): Failed to load icon.scss which is linked via styleUrls

Whilst still being able to execute tests at command, I simply cannot get them to execute from within webstorm itself

@lmame
Copy link

lmame commented Jul 26, 2019

@ronnyek, ok so I found a solution, at least for us internally, it might work for you as well maybe (?).

We have a project with several libs. Each lib has its own jest.config.js which refer to the "main" jest.config.js.

I had to:

  • Update jest-preset-angular to 7.1.1 (which you did),
  • In each lib where you launch your unit test have a /src/ folder with a file "test-setup.js" with this content:
    import 'jest-preset-angular';
  • Then add those lines in the main jest.config.js (at the end of the file):
   module.exports.globals = {
    'ts-jest': {
      tsConfig: 'tsconfig.spec.json',
      stringifyContentPathRegex: '\\.html$',
      astTransformers: [require.resolve('jest-preset-angular/InlineHtmlStripStylesTransformer')]
    }
  };

  module.exports.setupFilesAfterEnv = ['<rootDir>/src/test-setup.ts'];

Check if this works.

Though I think it broke the command line execution because it seems Nrwl is using a deprecated command "setupTestFrameworkScriptFile" in their jest files instead of "setupFilesAfterEnv".

So we had to know when the test was launched from Webstorm or command line. For that I simply set an environment variable in the Webstorm Jest template:
image

Then in the jest.config.js I am testing if the environment variable is set or not:

if (process.env.WEBSTORM !== undefined) {
  module.exports.globals = {
    'ts-jest': {
      tsConfig: 'tsconfig.spec.json',
      stringifyContentPathRegex: '\\.html$',
      astTransformers: [require.resolve('jest-preset-angular/InlineHtmlStripStylesTransformer')]
    }
  };

  module.exports.setupFilesAfterEnv = ['<rootDir>/src/test-setup.ts'];
}

I guess you might have to adapt for your uses...

@ronnyek
Copy link

ronnyek commented Aug 2, 2019

Tests that involve nothing with scss files, actually do run with what I had setup before... but there is something about this that is failing, but only when launched from webstorm.

It's currently complaining about not being able to load "icon.scss" which doesn't error.

I dont know if its related or not, but I noticed I get this output even when the other tests run and complete successfully.

ts-jest[config] (WARN) TypeScript diagnostics (customize using `[jest-config].globals.ts-jest.diagnostics` option):
message TS151001: If you have issues related to imports, you should consider setting `esModuleInterop` to `true` in your TypeScript configuration file (usually `tsconfig.json`). See https://blogs.msdn.microsoft.com/typescript/2018/01/31/announcing-typescript-2-7/#easier-ecmascript-module-interoperability for more information.

And all this is after trying to make some of the changes you suggested

@philly-vanilly
Copy link

Options: setupTestFrameworkScriptFile and setupFilesAfterEnv cannot be used together.
😞

@philly-vanilly
Copy link

So ATM I have the option between running the test in a pipeline or running individual tests via IntelliJ. One forbids using setupFilesAfterEnv, the other requires it.

@dsebastien
Copy link

Could this issue be reopened?
The problem actually seems to still be there and it feels utterly wrong to have to add an environment to the Jest config in IntelliJ/WebStorm to decide whether to adapt the configuration or not.

@dsebastien
Copy link

@wesleygrimes Wes, I don't know if you could chime in, or maybe pass the info to another Nx developer who knows about the Jest setup?

@SOHELAHMED7
Copy link

Reference to the key "setupFilesAfterEnv" is here: https://jestjs.io/docs/en/configuration#setupfilesafterenv-array

@ThomasBurleson
Copy link
Contributor

ThomasBurleson commented Dec 3, 2019

@vsavkin - This problem still exists with Nx library schematics. It appears that developers must still manually apply this fix to the jest config:

{
  "setupFilesAfterEnv": [  "<rootDir>/src/test-setup.ts" ]
}

@nezed
Copy link

nezed commented Dec 18, 2019

Found that specifying setupFile for builder overrides all and any setupFilesAfterEnv.

if (options.setupFile) {
config.setupFilesAfterEnv = [
path.resolve(context.workspaceRoot, options.setupFile)
];
}

PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Dec 19, 2019
- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Dec 20, 2019
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Jan 16, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Jan 24, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Feb 18, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @BabylonJS & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Feb 18, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @BabylonJS & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream
@chaoyangnz
Copy link

My solution:

add setupFilesAfterEnv: ["<rootDir>/src/test-setup.ts"] to jest.conf.js and remove "setupFile": "<...>/src/test-setup.ts" in angular.json.

It works for both npm test and run with webstorm.

For some guys got the error: connect ECONNREFUSED 127.0.0.1:80 even all test passed when
run component tests, you probably need to add this to jest.conf.js:

  globals: {
    'ts-jest': {
      diagnostics: false,
      stringifyContentPathRegex: '\\.html$',
      astTransformers: [require.resolve('jest-preset-angular/InlineHtmlStripStylesTransformer')],
    },
  }

PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Mar 6, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @BabylonJS & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* feat(ui): session-dialog with radio-group (#37)

* feat(ui): add basic skeleton for session-dialog

* feat(ui): session-dialog with radio-group

* test(ui): fix providers for session-dialog spec

* feat(frontend): open session-dialog via menu-bar

* test(frontend): check emitted action `selectSession`

* refactor(lib): s/session/topic

* refactor(lib): select or create a topic

* fix(frontend): voxels on wrong position due unresized canvas

* test(frontend): mock dialog result `UiTopicDialogSelectionResult`

* feat(kafka): add kafka-proxy (websocket) & kafka with docker-comp… (#38)

* feat(kafka): use `docker-compose` to start `kafka` & `Kafdrop`

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka 2

* feat(kafka): compress ws data & regsiter to connection state

* fix(frontend): missing dep. & comment out initial ws test emit

* feat(frontend): use `connectionStatus$` for status-bar

* feat(frontend): basic synchronisation of actions between ws-connections

* feat(frontend): sync editor & undo/redo actions

* feat(frontend): set `needsSync` in effect

* feat(frontend): set `needsSync` in effect

* feat(kafka-proxy): remove `identity` method

* test(frontend): mock & check dispatch

* test(frontend): add `needsSync: true`

* refactor(kafka): add project to nx ignore since it's not a real nx-app

* doc(kafka-proxy): add readme

* test(frontend): add generic parameter to fix error:

- Error: connect ECONNREFUSED 127.0.0.1:80

* test(frontend): put correct describe name (MenuBarContainerComponent)

* test(ui): import relative

* test(frontend/ui): specify globals in `jest.config.js`

- preventing `Error: connect ECONNREFUSED 127.0.0.1:80` when started
from WebStorm

* test(frontend/kafka-proxy): use `socket.broadcast` (send to all but me)

* test(frontend): prefer `io.connect` for readability

* refactor(kafka-proxy): extract kafka logic into `KafkaService` + tests

* refactor(frontend/kafka-proxy): basic create/delete/get topic(s)

* refactor(frontend/kafka-proxy): make topics an observable

* refactor(frontend): don't wrap observable with `new Actions()`

* refactor(frontend): emit `updateTopics` action when `kafkaPrSer.topics$`

* test(frontend): add `sessions` to state & update tests

* feat(frontend): set sessions in store & provide it in session-dialog

* feat(frontend): set `session`

* feat(frontend): s/AllActions/SyncAction

* feat(frontend/kafka-proxy): Consume topic & emit actions for viewer

* feat(kafka-proxy): remove old consumers on connection close

* refactor(frontend/kafka-proxy): extract `EventName` to `@talus/model`

* refactor(shared): extract `notNil()` to `@talus/shared`

* refactor(kafka-proxy): remove scaffolded files

* test(kafka-proxy): update gate tests

* fix(frontend): s/session(s)/topic(s) after rebase

* refactor(frontend): s/session/topic

* feat(kafka): start-up 'kafka-manager' to have more info

* refactor(frontend): extract `initialize()` for reuse

* feat(kafka-proxy): provide `resetOffsets()`

* feat(frontend): add `createTopic` action

* feat(ui): provide `disposeSceneAndRestartRendering()`

* feat(frontend/kafka-proxy): consumption of different topics

* fix(frontend): don't sync start/end-line action (effects emit them)

* fix(frontend): only emit action from kafka which have a diff. socket-id

* fix(frontend): load all messages from current "session" when re-open it

* refactor(frontend): remove `AfterViewInit` and order ctor arguments

* refactor(kafka): add (commented) `kafka-magic` UI as alternative

* refactor(kafka-proxy): move consumer management into `kafka.service.ts`

* doc(kafka-proxy): add links about REST proxy & kafkajs issue to readme

* style(kafka): fix prettier

* fix(frontend): filter `__consumer_offsets` from topics

* feat(frontend): get topics with total topic offset

* feat(ui): support status text in status-bar

* refactor(frontend): remove voxel count from state/reducer/specs

* refactor(frontend): update state if connection-status changed & fix test

* refactor(frontend): don't sync undo/redo, but setVoxels action

* fix(frontend): remove old parameter for undo action

* refactor(frontend): remove duplicated undo/redo action

* doc: add last generation step, macro & release links

* refactor(frontend): use `Promise.resolve()`

* fix(frontend): don't add initial voxel when existing topic loaded

* fix(kafka-proxy): return observable, so frontend gets new topic names

* test(frontend): adapt test for `needsSync` & initial action

* build(dep): update `@nrwl/workspace` to `v9.0.4`

* build(dep): update `@angular` to `v9.0.4`

* build(dep): update `@babylonjs` to `v4.1.0`

* build(dep): update `@babel` & '@nestjs' and use `--async=false` (CI)

* build(dep): update `tslib`, `@storybook`, `@types`, `@typescript-eslint`

* build(dep): update `cypress`

* test(kafka-proxy): mock `disconnectConsumer()`

* build(dep): update `@angular` to `v9.0.5`

* feat(ui): leaf empty space on top/bottom of sidenav panel

* refactor(frontend): use h6 and materials typography

* refactor(ui): make collapse button smaller

* feat(ui): add story for sidenav-shell component

* build(dep): update `@babel/core` to `v7.8.7`

* refactor(frontend): remove unused `Nil` type (moved to shared)

* refactor(kafka): specify specific image versions

* refactor(ui): make canvas background color transparent

* feat(frontend): get `lastLoadedMessageOffset` for future loading status
@ronnyek
Copy link

ronnyek commented Mar 13, 2020

@chaoyangnz Have you been able to run tests against components that have external html files / css files?

@chaoyangnz
Copy link

chaoyangnz commented Mar 13, 2020

@chaoyangnz Have you been able to run tests against components that have external html files / css files?

yup, all fine, components with inline and external html/css

PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Apr 3, 2020
* build(CircleCi): set upstream (#36)

* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @BabylonJS & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* Release v0.0.5 (#39)

* build(dep): `@babylonjs` & `@types/node`:

- @BabylonJS:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- jest-community/vscode-jest#486 (comment)

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- nrwl/nx#1439 (comment)

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @BabylonJS, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @BabylonJS & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* feat(ui): session-dialog with radio-group (#37)

* feat(ui): add basic skeleton for session-dialog

* feat(ui): session-dialog with radio-group

* test(ui): fix providers for session-dialog spec

* feat(frontend): open session-dialog via menu-bar

* test(frontend): check emitted action `selectSession`

* refactor(lib): s/session/topic

* refactor(lib): select or create a topic

* fix(frontend): voxels on wrong position due unresized canvas

* test(frontend): mock dialog result `UiTopicDialogSelectionResult`

* feat(kafka): add kafka-proxy (websocket) & kafka with docker-comp… (#38)

* feat(kafka): use `docker-compose` to start `kafka` & `Kafdrop`

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka 2

* feat(kafka): compress ws data & regsiter to connection state

* fix(frontend): missing dep. & comment out initial ws test emit

* feat(frontend): use `connectionStatus$` for status-bar

* feat(frontend): basic synchronisation of actions between ws-connections

* feat(frontend): sync editor & undo/redo actions

* feat(frontend): set `needsSync` in effect

* feat(frontend): set `needsSync` in effect

* feat(kafka-proxy): remove `identity` method

* test(frontend): mock & check dispatch

* test(frontend): add `needsSync: true`

* refactor(kafka): add project to nx ignore since it's not a real nx-app

* doc(kafka-proxy): add readme

* test(frontend): add generic parameter to fix error:

- Error: connect ECONNREFUSED 127.0.0.1:80

* test(frontend): put correct describe name (MenuBarContainerComponent)

* test(ui): import relative

* test(frontend/ui): specify globals in `jest.config.js`

- preventing `Error: connect ECONNREFUSED 127.0.0.1:80` when started
from WebStorm

* test(frontend/kafka-proxy): use `socket.broadcast` (send to all but me)

* test(frontend): prefer `io.connect` for readability

* refactor(kafka-proxy): extract kafka logic into `KafkaService` + tests

* refactor(frontend/kafka-proxy): basic create/delete/get topic(s)

* refactor(frontend/kafka-proxy): make topics an observable

* refactor(frontend): don't wrap observable with `new Actions()`

* refactor(frontend): emit `updateTopics` action when `kafkaPrSer.topics$`

* test(frontend): add `sessions` to state & update tests

* feat(frontend): set sessions in store & provide it in session-dialog

* feat(frontend): set `session`

* feat(frontend): s/AllActions/SyncAction

* feat(frontend/kafka-proxy): Consume topic & emit actions for viewer

* feat(kafka-proxy): remove old consumers on connection close

* refactor(frontend/kafka-proxy): extract `EventName` to `@talus/model`

* refactor(shared): extract `notNil()` to `@talus/shared`

* refactor(kafka-proxy): remove scaffolded files

* test(kafka-proxy): update gate tests

* fix(frontend): s/session(s)/topic(s) after rebase

* refactor(frontend): s/session/topic

* feat(kafka): start-up 'kafka-manager' to have more info

* refactor(frontend): extract `initialize()` for reuse

* feat(kafka-proxy): provide `resetOffsets()`

* feat(frontend): add `createTopic` action

* feat(ui): provide `disposeSceneAndRestartRendering()`

* feat(frontend/kafka-proxy): consumption of different topics

* fix(frontend): don't sync start/end-line action (effects emit them)

* fix(frontend): only emit action from kafka which have a diff. socket-id

* fix(frontend): load all messages from current "session" when re-open it

* refactor(frontend): remove `AfterViewInit` and order ctor arguments

* refactor(kafka): add (commented) `kafka-magic` UI as alternative

* refactor(kafka-proxy): move consumer management into `kafka.service.ts`

* doc(kafka-proxy): add links about REST proxy & kafkajs issue to readme

* style(kafka): fix prettier

* fix(frontend): filter `__consumer_offsets` from topics

* feat(frontend): get topics with total topic offset

* feat(ui): support status text in status-bar

* refactor(frontend): remove voxel count from state/reducer/specs

* refactor(frontend): update state if connection-status changed & fix test

* refactor(frontend): don't sync undo/redo, but setVoxels action

* fix(frontend): remove old parameter for undo action

* refactor(frontend): remove duplicated undo/redo action

* doc: add last generation step, macro & release links

* refactor(frontend): use `Promise.resolve()`

* fix(frontend): don't add initial voxel when existing topic loaded

* fix(kafka-proxy): return observable, so frontend gets new topic names

* test(frontend): adapt test for `needsSync` & initial action

* build(dep): update `@nrwl/workspace` to `v9.0.4`

* build(dep): update `@angular` to `v9.0.4`

* build(dep): update `@babylonjs` to `v4.1.0`

* build(dep): update `@babel` & '@nestjs' and use `--async=false` (CI)

* build(dep): update `tslib`, `@storybook`, `@types`, `@typescript-eslint`

* build(dep): update `cypress`

* test(kafka-proxy): mock `disconnectConsumer()`

* build(dep): update `@angular` to `v9.0.5`

* feat(ui): leaf empty space on top/bottom of sidenav panel

* refactor(frontend): use h6 and materials typography

* refactor(ui): make collapse button smaller

* feat(ui): add story for sidenav-shell component

* build(dep): update `@babel/core` to `v7.8.7`

* refactor(frontend): remove unused `Nil` type (moved to shared)

* refactor(kafka): specify specific image versions

* refactor(ui): make canvas background color transparent

* feat(frontend): get `lastLoadedMessageOffset` for future loading status
PhilippeMorier added a commit to PhilippeMorier/talus that referenced this issue Apr 6, 2020
* build(dep): `@babylonjs` & `@types/node`:

- @babylonjs:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- https://github.com/jest-community/vscode-jest/issues/486#issuecomment-563164125

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- https://github.com/nrwl/nx/issues/1439#issuecomment-561268656

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @babylonjs, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @babylonjs & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* feat(ui): session-dialog with radio-group (#37)

* feat(ui): add basic skeleton for session-dialog

* feat(ui): session-dialog with radio-group

* test(ui): fix providers for session-dialog spec

* feat(frontend): open session-dialog via menu-bar

* test(frontend): check emitted action `selectSession`

* refactor(lib): s/session/topic

* refactor(lib): select or create a topic

* fix(frontend): voxels on wrong position due unresized canvas

* test(frontend): mock dialog result `UiTopicDialogSelectionResult`

* feat(kafka): add kafka-proxy (websocket) & kafka with docker-comp… (#38)

* feat(kafka): use `docker-compose` to start `kafka` & `Kafdrop`

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka 2

* feat(kafka): compress ws data & regsiter to connection state

* fix(frontend): missing dep. & comment out initial ws test emit

* feat(frontend): use `connectionStatus$` for status-bar

* feat(frontend): basic synchronisation of actions between ws-connections

* feat(frontend): sync editor & undo/redo actions

* feat(frontend): set `needsSync` in effect

* feat(frontend): set `needsSync` in effect

* feat(kafka-proxy): remove `identity` method

* test(frontend): mock & check dispatch

* test(frontend): add `needsSync: true`

* refactor(kafka): add project to nx ignore since it's not a real nx-app

* doc(kafka-proxy): add readme

* test(frontend): add generic parameter to fix error:

- Error: connect ECONNREFUSED 127.0.0.1:80

* test(frontend): put correct describe name (MenuBarContainerComponent)

* test(ui): import relative

* test(frontend/ui): specify globals in `jest.config.js`

- preventing `Error: connect ECONNREFUSED 127.0.0.1:80` when started
from WebStorm

* test(frontend/kafka-proxy): use `socket.broadcast` (send to all but me)

* test(frontend): prefer `io.connect` for readability

* refactor(kafka-proxy): extract kafka logic into `KafkaService` + tests

* refactor(frontend/kafka-proxy): basic create/delete/get topic(s)

* refactor(frontend/kafka-proxy): make topics an observable

* refactor(frontend): don't wrap observable with `new Actions()`

* refactor(frontend): emit `updateTopics` action when `kafkaPrSer.topics$`

* test(frontend): add `sessions` to state & update tests

* feat(frontend): set sessions in store & provide it in session-dialog

* feat(frontend): set `session`

* feat(frontend): s/AllActions/SyncAction

* feat(frontend/kafka-proxy): Consume topic & emit actions for viewer

* feat(kafka-proxy): remove old consumers on connection close

* refactor(frontend/kafka-proxy): extract `EventName` to `@talus/model`

* refactor(shared): extract `notNil()` to `@talus/shared`

* refactor(kafka-proxy): remove scaffolded files

* test(kafka-proxy): update gate tests

* fix(frontend): s/session(s)/topic(s) after rebase

* refactor(frontend): s/session/topic

* feat(kafka): start-up 'kafka-manager' to have more info

* refactor(frontend): extract `initialize()` for reuse

* feat(kafka-proxy): provide `resetOffsets()`

* feat(frontend): add `createTopic` action

* feat(ui): provide `disposeSceneAndRestartRendering()`

* feat(frontend/kafka-proxy): consumption of different topics

* fix(frontend): don't sync start/end-line action (effects emit them)

* fix(frontend): only emit action from kafka which have a diff. socket-id

* fix(frontend): load all messages from current "session" when re-open it

* refactor(frontend): remove `AfterViewInit` and order ctor arguments

* refactor(kafka): add (commented) `kafka-magic` UI as alternative

* refactor(kafka-proxy): move consumer management into `kafka.service.ts`

* doc(kafka-proxy): add links about REST proxy & kafkajs issue to readme

* style(kafka): fix prettier

* fix(frontend): filter `__consumer_offsets` from topics

* feat(frontend): get topics with total topic offset

* feat(ui): support status text in status-bar

* refactor(frontend): remove voxel count from state/reducer/specs

* refactor(frontend): update state if connection-status changed & fix test

* refactor(frontend): don't sync undo/redo, but setVoxels action

* fix(frontend): remove old parameter for undo action

* refactor(frontend): remove duplicated undo/redo action

* doc: add last generation step, macro & release links

* refactor(frontend): use `Promise.resolve()`

* fix(frontend): don't add initial voxel when existing topic loaded

* fix(kafka-proxy): return observable, so frontend gets new topic names

* test(frontend): adapt test for `needsSync` & initial action

* build(dep): update `@nrwl/workspace` to `v9.0.4`

* build(dep): update `@angular` to `v9.0.4`

* build(dep): update `@babylonjs` to `v4.1.0`

* build(dep): update `@babel` & '@nestjs' and use `--async=false` (CI)

* build(dep): update `tslib`, `@storybook`, `@types`, `@typescript-eslint`

* build(dep): update `cypress`

* test(kafka-proxy): mock `disconnectConsumer()`

* build(dep): update `@angular` to `v9.0.5`

* feat(ui): leaf empty space on top/bottom of sidenav panel

* refactor(frontend): use h6 and materials typography

* refactor(ui): make collapse button smaller

* feat(ui): add story for sidenav-shell component

* build(dep): update `@babel/core` to `v7.8.7`

* refactor(frontend): remove unused `Nil` type (moved to shared)

* refactor(kafka): specify specific image versions

* refactor(ui): make canvas background color transparent

* feat(frontend): get `lastLoadedMessageOffset` for future loading status

* build(dep): update nrwl & ng (#40)

* build(dep): update `@nrwl` to `v9.1.0`

* doc(frontend): how to update `ng`

* build(dep): update `@angular`

* build(CircleCI): s/nx build benchmark/ng build benchmark

* build(dep): update @types, eslint, stylelint

* build(dep): update @angular

* feat(frontend): load obj in web worker & display progress-spinner (#42)

* refactor(frontend): emit only if connection status changes

* doc(ui): add how to add new module & component with `ng g`

* refactor(shared): export `Nil` type

* feat(ui): add fullscreen-overlay module

* feat(ui): add simple progress-spinner component

* feat(ui): set `ChangeDetectionStrategy.OnPush`

* doc(kafka): stop/remove all docker containers with values

* refactor(ui): export progress-spinner module & include it in specs

* feat(frontend): add web worker for loading obj file

* feat(frontend): show progress-spinner while loading obj in worker

* test(frontend): provide mocks

* style(frontend): fix order

* build(dep): update outdated dependencies (#43)

* build(dep): bump `@nestjs` to `7.0.3`

* build(dep): bump `@nrwl` to `9.1.2`

* build(dep): bump div dep

* build(dep): bump @angular cdk & material

* build(dep): bump `cypress`, `zone.js` & `jest-preset-angular`

* build(dep): revert to `eslint/parser` `2.23.0`:

- https://github.com/typescript-eslint/typescript-eslint/issues/1746

* refactor(frontend): add comment about not dispatching action with `File`

* feat(ui): introduce theming & theme progress-spinner (#44)

* build(dep): update lock file

* build(dep): update `@angular` to `9.0.7`

* build(dep): update `@babel`, `stylelint` & `ts-node`

* build(dep): update `@nextjs`

* build(dep): update `prettier`

* feat(vdb): make lib publishable

* feat(vdb): add `mnemonist` as dependency

* feat(vdb): add usage

* feat(vdb): add missing dependency `tslib`

* refactor(benchmark): rename app s/benchmark/benchmarks due linting issue

- no need to put project into `.nxignore`
- project can be linted now

* doc(vdb): add example code & homepage URL

* refactor(lib): adjust min-width to work with 96 dpi

* refactor(lib): adjust font-size to work with 96 dpi

* refactor(lib): adjust margins to work with 96 dpi

* refactor(lib): adjust translate to work with 96 dpi

* refactor(lib): adjust font/icon size for 96 dpi

* refactor(lib): adjust margin for 96 dpi

* feat(ui): add `rectangular marquee` component (#45)

* refactor(lib): adjust min-width to work with 96 dpi

* refactor(lib): adjust font-size to work with 96 dpi

* refactor(lib): adjust margins to work with 96 dpi

* refactor(lib): adjust translate to work with 96 dpi

* refactor(lib): adjust font/icon size for 96 dpi

* refactor(lib): adjust margin for 96 dpi

* feat(ui): add `rectangular-marquee` component

* refactor(ui): set `OnPush` and use `OnInit`

* test(ui): use `AfterViewInit` with `OnInit`

* refactor(ui): add barrel index

* refactor(ui): put gizmos at top-left corner

* refactor(ui): add story for scene-viewer

* refactor(lib): export all

* fix(frontend): undo when cancel drawing a line (#47)

* fix(frontend): undo when cancel drawing a line

* style(frontend): fix Prettier issue

* test(frontend): provide mock store & actions

* refactor: resolve conflicts (#48)

* build(CircleCi): set upstream (#36)

* build(dep): `@babylonjs` & `@types/node`:

- @babylonjs:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- https://github.com/jest-community/vscode-jest/issues/486#issuecomment-563164125

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- https://github.com/nrwl/nx/issues/1439#issuecomment-561268656

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @babylonjs, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @babylonjs & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* Release v0.0.5 (#39)

* build(dep): `@babylonjs` & `@types/node`:

- @babylonjs:4.1.0-beta.9
- @types/node:12.12.16

* feat(apps/frontend): select initial tool

* fix(apps/frontend): import hammerjs

* refactor(frontend): scene-viewer into container

* feat(frontend): dispatch `pointerPick` action

* feat(frontend): dispatch `add|removeVoxel` action

* build(packaging): simplify `prettier:check` command

* doc(frontend): add readme with ngrx resources

* feat(frontend): support adding voxel

* refactor(frontend): don't inject `GridService`

* feat(frontend): effects for when app goes on/offline

* test(frontend): on/offline effects

* test(vdb): remove `normals` from test

* feat(vdb): add `setValueOff` & `isValueOn`

* test(frontend): set expected position to pass

* fix(frontend): make public for use in template

* build(dep): `@types/node` & `core-js`

* feat(frontend): enable `removeVoxel`

* build(dep): `@babylonjs/*`

* build(github): keep `develop` after PR merge

* build(dep): `cypress` to `v3.8.0`

* build(dep): `cypress` to `v3.7.0`

* test(vdb): set value with float coordinates:

- coordinates get always rounded down

* build(dep): `cypress` to `v3.7.0`

* feat(frontend): support adding and removing voxels

* test(ui): remove unused imported components

* build(CircleCi): use `13.3.0` due failing tests:

- Test suite failed to run
  - Call retries were exceeded at ChildProcessWorker.initialize()
- https://github.com/jest-community/vscode-jest/issues/486#issuecomment-563164125

* fix(frontend): add voxel on positive normal

- but negative position

* test(frontend): set `setupFilesAfterEnv`

- to run in Jest tests within WebStorm
- https://github.com/nrwl/nx/issues/1439#issuecomment-561268656

* test(frontend): set `globals`>`tsConfig`

- to run in Jest tests within WebStorm with SCSS imports in component

* build(CircleCi): use `13.4.0`

* build(dep): update diverse dependencies:

- @ngrx/effects, @ngrx/store
- core-js, mnemonist, codelyzer
- @types/jest, @types/node

* doc(readme): record macro & git setup

* build(dep): `@angular-devkit/build-angular` & `@angular/cli`

* feat(frontend): draw separate mesh per InternalNode1 (#9)

* feat(frontend): add multiple voxels

* feat(ui): add output for dropped files

* doc(readme): add openVDB repo link

* feat(vdb): implement `beginLeafOn` iterator

* feat(frontend/vdb): draw InternalNode1 chunks

* feat(frontend/vdb): don't return LeafNode

* feat(frontend/vdb): don't return `LeafNode` in `setValueAndCache`

* feat(frontend/vdb): use only key from accessor

* feat(frontend/vdb): remove `getLeafNodeAndCache`

* feat(frontend/vdb): remove `beginLeafOn`

* feat(frontend/vdb): remove `getLeafNodeAndCache` & `beginLeafOn`

* fix(frontend/vdb): dispose mesh instead of just remove it:

- so we resolve memory issue

* refactor(frontend): optimize scene & mesh

- https://doc.babylonjs.com/how_to/optimizing_your_scene

* refactor(frontend): remove unused method & obj loader

* refactor(vdb): increase `InternalNode1` size to reduce draw calls

* refactor(vdb): remove inspector & loading obj

* refactor(vdb): align to `probeNode` & `probeNodeAndCache`

* refactor(vdb): s/grid-to-mesh/node-to-mesh

* refactor(vdb): use un-indexed mesh

* fix(ui): read normal directly from picked mesh

* refactor(frontend): remove `objFileLoader`

* refactor(frontend): s/updateGridMesh/updateNodeMesh & key/Node1Origin

* feat(benchmark): test single vs. multiple `array.push()`

* build(CircleCi): update node to `13.5.0` & cypress `3.8.1`

* build(nx): nx migrate @nrwl/workspace (v8.11.0)

- nx migrate --run-migrations=migrations.json

* fix(benchmark): add `.nxignore` to get benchmark through linter

* build(dep): update dependencies

* feat(frontend): add undo/redo & enable `strictNullChecks` (#10)

* feat(frontend): add undo/redo & enforce `strictNullChecks`

* feat(frontend): undo/redo with max buffer size

* test(frontend): handle possible `undefined`

* feat(frontend): make remove a voxel undoable

* feat(frontend): place initial voxel at [0, 0, 0]

* fix(frontend): dispose previous history if new `addUndo`

* refactor(frontend): extract method for creating `addUndo`

* feat(frontend): set active state of voxel, return color when deleting (#11)

* feat(ui/frontend): add menu-bar (#12)

* feat(frontend): add menu-bar

* feat(frontend): add menu-bar-container

* test(frontend): inject mock store for menu-bar-container

* refactor(frontend): add missing `menu-bar.component`

* test(frontend): import `MenuBarModule`

* feat(frontend): undo/redo with start/end actions (#13)

* feat(frontend): undo/redo with start/end actions

* test(frontend): provide `valueToColor()`

* feat(frontend): set random color when adding a voxel

* test(frontend): add same color of voxel

* refactor(frontend): use directly `props<VoxelChange>`

* refactor(frontend): throw error when coord&values not same length

* build(dep): update dependencies

* build(dep): update cypress to `v3.8.2`

* build(dep): update stylelint to `v13.0.0`

* refactor(ui): prefix UI components with `Ui` like Angular does with `Mat` (#14)

* refactor(ui): prefix `MenuBar` with `Ui` like Angular does with `Mat`

* refactor(ui): prefix `SceneViewer` with `Ui` as Angular does with `Mat`

* test(ui): check `menu-bar` menus & items

* refactor(ui): remove ctor & onInit

* test(ui): check if sidnav has left & right navigation

* refactor(ui): prefix `SidenavShell` with `Ui` as Angular does with `Mat`

* refactor(ui): prefix `SceneViewerService` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `SceneViewerTestModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `ToolbarModule` with `Ui` (ng with `Mat`)

* refactor(ui): prefix `UiPointer[Button|PickInfo]` with `Ui`

* build(dep): update handlebars to `v4.7.2` due to security issues

* test(ui): should emit `value` of clicked menu items

* test(ui): should emit on tool select

* test(ui): should close left & right sidenav

* test(frontend): should dispatch action

* test(frontend): check `scene-viewer-container.reducer`

* test(frontend): check `scene-viewer-container.reducer` selector

* refactor(ui): import `hammerjs` to remove warning in test run

* test(frontend): check `tools-panel.reducer`

* test(frontend): check `undo-redo.reducer`

* test(frontend): check `undo-redo.reducer` with `stepX`

* test(frontend): check `undo-redo.reducer` too many undo/redo's

* style(prettier): fix imports

* test(vdb): add tests for `tree`

* test(vdb): improve coverage

* test(vdb): check coord

* test(vdb): check grid

* test(vdb): check `nodeToMesh`

* feat(ui): add `Storybook` (#16)

* feat(ui): add `Storybook`

* feat(ui): add `Storybook` e2e test

* doc(ui): how to watch e2e

* build(dep): update storybook to `v5.3.6`

* build(dep): back to storybook `v5.3.2` due to:

- info => Using angular project 'frontend' for configuring Storybook.

* build(dep): back to storybook `v5.3.6` since it works

* test(ui-e2e): open/close `menu-bar`

* ci(storybook): run, build & deploy storybook for `ui-e2e` (#17)

* ci(storybook): build storybook

* ci(storybook): move `frontend e2e` step down

* ci(storybook): store storybook & deploy to gh-pages

* ci(storybook): extract git(hub) configs

* ci(storybook): extract deploy to gh-pages

* ci(storybook): change to `test-results` folder & use `junit` reporter

* ci(storybook): run `ui-e2e` and store test-results & artifacts

* ci(storybook): run `ui-e2e` only on `master` & `develop`

* fix(ui): to high/large canvas by setting `display: block;`

* feat(frontend): paint voxel (#18)

* feat(frontend): dispatch paint-voxel action

* feat(frontend): set voxel on paint

* feat(frontend): finish renaming `addVoxel` to `setVoxel`

* feat(frontend): save old/new values and undo/redo painting

* refactor(frontend): s/positions/coord

* refactor(frontend): fix prettier issue

* refactor(frontend): s/position/xyz

* build(dep): update `@nrwl` to `v8.11.2`

* build(dep): update `@angular/(cli|core)` to `v8.3.22`

- `ng update @angular/cli @angular/core`

* build(dep): update @babylonjs, @babel, @storybook, @types

* feat(ui): color-dialog (#19)

* feat(ui): color-dialog

* refactor(ui): always open dialog in story

* refactor(ui): flatten config to just menus & type safety in story

* feat(ui): pass colors to color-dialog

* refactor(ui): make data & return value type-safe.

* refactor(ui): extract interface `UiColorDialogData`

* refactor(ui): extract open into `UiColorDialogService`

* test(ui): s/UiMenuBarConfig/UiMenuBarMenu

* refactor(ui): provide `selectedColorIndex`

* build(dep): update `circleci/node` to `v13.6.0`

* feat(frontend): use color-dialog (#20)

* feat(frontend): use color-dialog

* refactor(ui): s/draggable-dialog/color-dialog

* feat(frontend): open (empty) color-dialog

* feat(frontend): provide some first colors

* feat(frontend): use effects to open color-dialog

* feat(frontend): use effects to set selected color in store

* feat(frontend): temp. consider just `color.r`

* feat(frontend): save colors and selected-index

* refactor(frontend): move `tool.model.ts` to `model` (put in lib later)

* feat(frontend): `intToRgba` & `rgbaToInt`

* refactor(frontend): s/model/value

* refactor(frontend): use `Rgba` and `rgbaToInt` to set voxel in grid

* refactor(frontend): provide selector for retrieving CSS colors

* refactor(frontend): move comment `Front`

* refactor(vdb): define all colors

* refactor(frontend): fix prettier

* test(frontend): import `OptionsPanelModule`

* refactor(frontend): prettier

* refactor(ui): `forceDepthWrite` for transparent cubes

- there are still some artifacts (seeing through cubes behind)

* refactor(ui): use `rgba` to set initial voxel at [0, 0, 0]

* test(frontend): provide stub component in `AppComponent` test

* test(frontend): provide `initialMockState`

* test(frontend): mock & expect proper `Rgba` values

* test(ui): fix type of dialog result (`UiColorDialogColor` to `number`)

* feat(frontend): support dark & light theme (#21)

* feat(ui): add theme toggle to storybook (#22)

* feat(ui): remove `mat-button` from story

* build(dep): update `@storybook` to `v5.3.8`

* build(dep): update `tslint` to `v6.0.0`

* build(dep): back to `tslint` `v5.20.1`

* refactor(model): extract `Rgba` & `Tool` to lib `model` (#24)

* refactor(model): extract `Rgba` & `Tool` to lib `model`

* refactor(model): remove mapping path to non-existing `@talus/math`

* refactor(vdb): use `eslint` over `tslint` (#25)

* refactor(benchmark): use `eslint` over `tslint` (#26)

* refactor(benchmark): use `eslint` over `tslint`

* refactor(benchmark): s/benchmarkjs/Benchmark

* ci(circle): `git pull` before `gh-pages` deploy

* refactor(frontend): prefix unused variables with `_`

* refactor(frontend): register pointer events

* refactor(frontend): draw initial chessboard

* docs(talus): add ui-e2e command & update deploy url

* docs(frontend): add most used commands

* docs(vdb): move install & test to blog

* docs(ui): clean-up storybook commands

* feat(vdb): implement raytracing (#27)

* refactor(vdb): move `ValueType` & `Index` to `types.ts`

* feat(vdb): add delta value

* feat(vdb): add `floor()` to `Coord`

* feat(vdb): add `Vec3`

* feat(vdb): add `minValue` to `Vec3`

* feat(vdb): add `Ray`

* feat(vdb): implement `probeLeafNodeAndCache`

* test(vdb): improve comments about cache misses

* test(vdb): check if correct cache level was hit

* feat(frontend): add selection tool & stop moving camera on voxel hit

* refactor(benchmark): reduce amount of values (CircleCI)

* build(dep): update `node` to `v13.7.0`

* ci: start using `yarn nx ...`

* refactor(benchmark): set `--maxWorkers` to 10 (was 32 on CircleCI)

* ci: uniform calls by using `yarn nx ...`

* doc: add debug CircleCI via `ssh`

* feat(vdb): add `empty()` & `numBackgroundTiles()`

* feat(vdb): add `keyToCoord()`

* feat(vdb): `expand()` on `CoordBBox`

* feat(vdb): `isInside()` on `CoordBBox`

* feat(vdb): add `offset`, `expand`, `reset`, `translate`

* feat(vdb): add `add`, `divide` to `Vec3`

* feat(vdb): add `clip`, `intersects` & `setTimes` to `Ray`

* test(vdb): add C++ tests for `VolumeRayIntersector`, `Ray`, `Coord`

* feat(vdb): add `VolumeRayIntersector`

* style(vdb): eslint-disable @typescript-eslint/no-explicit-any

* test(vdb): min coord is `Number.MIN_SAFE_INTEGER`

* test(vdb): remove `console.log()`

* refactor(vdb): export `VolumeRayIntersector`

* test(vdb): add test with checking all voxels intersecting given ray

* refactor(vdb): organize imports with barrel files (1)

* feat(frontend): add basic line drawing (#28)

* refactor(frontend/vdb): remove `colors` & comments for `beginValueOn()`

* feat(vdb): add `removeFraction()`

* feat(frontend): add `Select line point` tool

* feat(frontend): add basic line drawing

* test(model): improve test description for `Rgba`

* style(frontend): fix prettier (imports)

* refactor(frontend): extract methods

* refactor(frontend): move declaration `dda` to usage

* build(dep): update @storybook, @types, @typescript-eslint, eslint

* build(CircleCI): `git co gh-pages` before pull and commit

* build(CircleCI): use `checkout` over not-existing `co` alias

* build(dep): migrate to `@nrwl` `v8.12.1`

* build(dep): keep `cypress` `v3.8.3`

* build(dep): `ng update @angular/cli` `v8.3.24`

* build(dep): `@babel/core` `v7.8.4`

* build(CircleCI): deploy in `$DEPLOY_CONTEXT` folder on `gh-pages`

* build(CircleCI): echo variables and `git fetch origin gh-pages:gh-pages`

* build(CircleCI): echo variables and `git pull`

* build(CircleCI): don't `echo` variables

* feat(ui): `pointUnderPointer$` emitting when hover over mesh

* build(CircleCI): adjust base-path (`apps/frontend`

* fix(frontend): return all `VoxelChange` & filter dupl. origins in effect

* test(vdb): check if accessor returns background

* test(vdb): should fill buffer with `0`

* test(vdb): should initialise with `0`

* test(vdb): check if accessor returns background

* feat(frontend): bg value = -1, `removeVoxel` uses `setValueOff`

* fix(frontned): import `VoxelChange`

* feat(frontend): preview line (#29)

* feat(frontend): preview line

* style(frontned): prettier

* test(frontend): provide `GridService`

* test(vdb): add C++ tests `testSetActiveState`

* feat(frontend): start & finish line drawing

* feat(frontend): temporary set start & end voxel of line

* feat(frontend): use `voxelsSet` action

* feat(frontend): support undo line drawing

* feat(frontend): pass position to chessboard

* refactor(frontend): use only one coord `selectedLineStartCoord`

* test(frontend): check `scene-viewer-container.reducer.ts`

* test(frontend): check filter out duplicate origins in effect

* test(frontend): check `setVoxel(s)` & `setVoxel(s)Failed`

* doc(frontend): update readme with 'Angular Update Guide'

* test(frontend): extract voxel change

* refactor: update to @angular 9.0.0 & cypress 4.0.0 (#30)

* refactor(ui/frontend): import deeply to specific material component

* build(dep): update `@angular/cli` to `v8.3.25`

* build(dep): update `@nrwl/*` to `v8.12.2`

* build(dep): update `@angular/*` to `v9`

* build(dep): update `@angular/material` to `v9`

* build(dep): update `@storybook`, `@typescript-eslint`

* build(dep): update `cypress` to `v4.0.0`

* build(dep): remove `handlebars`

* build(dep): update `@babylonjs`

* feat(vdb): add `touchLeafAndCache()` (#31)

* feat(vdb): add `touchLeafAndCache()`

* refactor(frontend): only set `end` temporary in `selectLine()`

* refactor(frontend): don't initialize with chessboard

* fix(frontend): not drawing of line in same node:

- probe for InternalNode1 for affected origin, don't use accessor

* refactor(frontend): use `tap` over `map`

* build(dep): update to `nx` `v9.0.0` (#34)

* build(dep): update to `nx` `v9.0.0`

* build(dep): update @storybook, @typescript-eslint, cypress, stylelint

* build(dep): update @babylonjs & conform to newly created nx workspace

* style(frontend): disable stylelint for angular theme color keys

* build(dep): update @angular to `9.0.1`

* build(dep): @storybook/*, @types/node, stylelint

* feat(ui): add basic status-bar with connection status

* feat(frontend): add empty status-bar

* feat(ui): use outlined icon for changing theme & put icon at bottom

* test(frontend): include `UiStatusBarModule`

* build(CircleCi): set upstream

* feat(ui): session-dialog with radio-group (#37)

* feat(ui): add basic skeleton for session-dialog

* feat(ui): session-dialog with radio-group

* test(ui): fix providers for session-dialog spec

* feat(frontend): open session-dialog via menu-bar

* test(frontend): check emitted action `selectSession`

* refactor(lib): s/session/topic

* refactor(lib): select or create a topic

* fix(frontend): voxels on wrong position due unresized canvas

* test(frontend): mock dialog result `UiTopicDialogSelectionResult`

* feat(kafka): add kafka-proxy (websocket) & kafka with docker-comp… (#38)

* feat(kafka): use `docker-compose` to start `kafka` & `Kafdrop`

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka

* feat(kafka): start kafka, use kafka-proxy to send msg via WS to kafka 2

* feat(kafka): compress ws data & regsiter to connection state

* fix(frontend): missing dep. & comment out initial ws test emit

* feat(frontend): use `connectionStatus$` for status-bar

* feat(frontend): basic synchronisation of actions between ws-connections

* feat(frontend): sync editor & undo/redo actions

* feat(frontend): set `needsSync` in effect

* feat(frontend): set `needsSync` in effect

* feat(kafka-proxy): remove `identity` method

* test(frontend): mock & check dispatch

* test(frontend): add `needsSync: true`

* refactor(kafka): add project to nx ignore since it's not a real nx-app

* doc(kafka-proxy): add readme

* test(frontend): add generic parameter to fix error:

- Error: connect ECONNREFUSED 127.0.0.1:80

* test(frontend): put correct describe name (MenuBarContainerComponent)

* test(ui): import relative

* test(frontend/ui): specify globals in `jest.config.js`

- preventing `Error: connect ECONNREFUSED 127.0.0.1:80` when started
from WebStorm

* test(frontend/kafka-proxy): use `socket.broadcast` (send to all but me)

* test(frontend): prefer `io.connect` for readability

* refactor(kafka-proxy): extract kafka logic into `KafkaService` + tests

* refactor(frontend/kafka-proxy): basic create/delete/get topic(s)

* refactor(frontend/kafka-proxy): make topics an observable

* refactor(frontend): don't wrap observable with `new Actions()`

* refactor(frontend): emit `updateTopics` action when `kafkaPrSer.topics$`

* test(frontend): add `sessions` to state & update tests

* feat(frontend): set sessions in store & provide it in session-dialog

* feat(frontend): set `session`

* feat(frontend): s/AllActions/SyncAction

* feat(frontend/kafka-proxy): Consume topic & emit actions for viewer

* feat(kafka-proxy): remove old consumers on connection close

* refactor(frontend/kafka-proxy): extract `EventName` to `@talus/model`

* refactor(shared): extract `notNil()` to `@talus/shared`

* refactor(kafka-proxy): remove scaffolded files

* test(kafka-proxy): update gate tests

* fix(frontend): s/session(s)/topic(s) after rebase

* refactor(frontend): s/session/topic

* feat(kafka): start-up 'kafka-manager' to have more info

* refactor(frontend): extract `initialize()` for reuse

* feat(kafka-proxy): provide `resetOffsets()`

* feat(frontend): add `createTopic` action

* feat(ui): provide `disposeSceneAndRestartRendering()`

* feat(frontend/kafka-proxy): consumption of different topics

* fix(frontend): don't sync start/end-line action (effects emit them)

* fix(frontend): only emit action from kafka which have a diff. socket-id

* fix(frontend): load all messages from current "session" when re-open it

* refactor(frontend): remove `AfterViewInit` and order ctor arguments

* refactor(kafka): add (commented) `kafka-magic` UI as alternative

* refactor(kafka-proxy): move consumer management into `kafka.service.ts`

* doc(kafka-proxy): add links about REST proxy & kafkajs issue to readme

* style(kafka): fix prettier

* fix(frontend): filter `__consumer_offsets` from topics

* feat(frontend): get topics with total topic offset

* feat(ui): support status text in status-bar

* refactor(frontend): remove voxel count from state/reducer/specs

* refactor(frontend): update state if connection-status changed & fix test

* refactor(frontend): don't sync undo/redo, but setVoxels action

* fix(frontend): remove old parameter for undo action

* refactor(frontend): remove duplicated undo/redo action

* doc: add last generation step, macro & release links

* refactor(frontend): use `Promise.resolve()`

* fix(frontend): don't add initial voxel when existing topic loaded

* fix(kafka-proxy): return observable, so frontend gets new topic names

* test(frontend): adapt test for `needsSync` & initial action

* build(dep): update `@nrwl/workspace` to `v9.0.4`

* build(dep): update `@angular` to `v9.0.4`

* build(dep): update `@babylonjs` to `v4.1.0`

* build(dep): update `@babel` & '@nestjs' and use `--async=false` (CI)

* build(dep): update `tslib`, `@storybook`, `@types`, `@typescript-eslint`

* build(dep): update `cypress`

* test(kafka-proxy): mock `disconnectConsumer()`

* build(dep): update `@angular` to `v9.0.5`

* feat(ui): leaf empty space on top/bottom of sidenav panel

* refactor(frontend): use h6 and materials typography

* refactor(ui): make collapse button smaller

* feat(ui): add story for sidenav-shell compo…
@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

9 participants