vaadin-component-factory / enhanced-dialog

Java API for vcf-enhanced-dialog component
https://incubator.app.fi/enhanced-dialog-demo/enhanced-dialog
Apache License 2.0
1 stars 3 forks source link

Not working with V22 #17

Closed stefanuebe closed 2 years ago

stefanuebe commented 2 years ago

It seems like the EDialog is using some references, that are not there anymore in Vaadin 22?

Added the dependency to a fresh V22 starter project, used the first demo sample and tried to startup the application. This is the result:

------------------ Frontend compilation failed. ------------------

2021-12-09 09:33:56.792  INFO 2364 --- [onPool-worker-1] c.v.b.devserver.AbstractDevServerRunner  : Started Webpack. Time: 13792ms
2021-12-09 09:33:56.905  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : No issues found.
2021-12-09 09:33:57.680  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : Error from chokidar (C:\): Error: EBUSY: resource busy or locked, lstat 'C:\DumpStack.log.tmp'
2021-12-09 09:33:59.849  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : 
2021-12-09 09:33:59.849  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : WARNING in InjectManifest has been called multiple times, perhaps due to running webpack in --watch mode. The precache manifest generated after the first call may be inaccurate! Please see https://github.com/GoogleChrome/workbox/issues/1790 for more information.
2021-12-09 09:33:59.850  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : 
2021-12-09 09:33:59.850  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : ERROR in ../node_modules/.pnpm/@vaadin-component-factory/vcf-enhanced-dialog@21.0.0/node_modules/@vaadin-component-factory/vcf-enhanced-dialog/src/vcf-enhanced-dialog.js
2021-12-09 09:33:59.850  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : Module not found: Error: Can't resolve '@vaadin/vaadin-dialog/src/vaadin-dialog-utils' in 'C:\Arbeit\workspace\other\my-app-22\node_modules\.pnpm\@vaadin-component-factory\vcf-enhanced-dialog@21.0.0\node_modules\@vaadin-component-factory\vcf-enhanced-dialog\src'
2021-12-09 09:33:59.850  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : [build-status] 1 error and 1 warning were reported.
2021-12-09 09:33:59.850  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : [build-status] : Failed to compile.

------------------ Frontend compilation failed. ------------------

2021-12-09 09:33:59.860  INFO 2364 --- [v-server-output] c.v.b.devserver.DevServerOutputTracker   : No issues found.
stefanuebe commented 2 years ago

See https://github.com/vaadin-component-factory/vcf-enhanced-dialog/issues/4.

Seems like the old module "vaadin-dialog" is not referencing all files from "dialog" (e.g in this case the utils).

hfazai commented 2 years ago

+1

kklein-celera commented 2 years ago

+1

kklein-celera commented 2 years ago

Edit line 8 of @vaadin-component-factory/vcf-enhanced-dialog/src/vcf-enhanced-dialog.js to read:

import { getMouseOrFirstTouchEvent } from '@vaadin/dialog/src/vaadin-dialog-utils';

This appears to fix the problem.

hfazai commented 2 years ago

EnhancedDialog now supports V22 and V23 (#18), so you can close this issue. PS: it will be deprecated in later versions because the header and footer will be added to V 23.1