mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-23 22:25:05 +00:00
When in app mode, widgets can be drawn with size different from the size of the parent node. Mouse events on legacy canvas widgets require that the client code query the current state of the node and widget to determine if any elements are being interacted with. This PR sets the `widget.width` property when a legacy canvas widget draw operation occurs so that custom nodes can properly resolve subsequent mouse events. At current, no core nodes exist that utilize legacy widgets. As a result the setup code to test this bug fix is slightly involved. ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-11574-Fix-legacy-widget-width-in-app-mode-34b6d73d365081caaa34c6204f8361f6) by [Unito](https://www.unito.io)
84 lines
2.3 KiB
TypeScript
84 lines
2.3 KiB
TypeScript
import type { KnipConfig } from 'knip'
|
|
|
|
const config: KnipConfig = {
|
|
treatConfigHintsAsErrors: true,
|
|
workspaces: {
|
|
'.': {
|
|
entry: [
|
|
'{build,scripts}/**/*.{js,ts}',
|
|
'src/assets/css/style.css',
|
|
'src/scripts/ui/menu/index.ts',
|
|
'src/types/index.ts',
|
|
'src/storybook/mocks/**/*.ts'
|
|
],
|
|
project: ['**/*.{js,ts,vue}', '*.{js,ts,mts}', '!.claude/**']
|
|
},
|
|
'apps/desktop-ui': {
|
|
entry: ['src/i18n.ts'],
|
|
project: ['src/**/*.{js,ts,vue}']
|
|
},
|
|
'packages/design-system': {
|
|
project: ['src/**/*.{css,js,ts}']
|
|
},
|
|
'packages/tailwind-utils': {
|
|
project: ['src/**/*.{js,ts}']
|
|
},
|
|
'packages/shared-frontend-utils': {
|
|
project: ['src/**/*.{js,ts}']
|
|
},
|
|
'packages/registry-types': {
|
|
project: ['src/**/*.{js,ts}']
|
|
},
|
|
'packages/ingest-types': {
|
|
project: ['src/**/*.{js,ts}']
|
|
},
|
|
'apps/website': {
|
|
entry: ['src/scripts/**/*.ts']
|
|
}
|
|
},
|
|
ignoreBinaries: ['python3'],
|
|
ignoreDependencies: [
|
|
// Weird importmap things
|
|
'@iconify-json/lucide',
|
|
'@iconify/json',
|
|
'@primeuix/forms',
|
|
'@primeuix/styled',
|
|
'@primeuix/utils',
|
|
'@primevue/icons'
|
|
],
|
|
ignore: [
|
|
// Auto generated API types
|
|
'src/workbench/extensions/manager/types/generatedManagerTypes.ts',
|
|
'packages/ingest-types/src/zod.gen.ts',
|
|
// Workflow files contain license names that knip misinterprets as binaries
|
|
'.github/workflows/ci-oss-assets-validation.yaml',
|
|
// Pending integration in stacked PR
|
|
'src/components/sidebar/tabs/nodeLibrary/CustomNodesPanel.vue',
|
|
// Agent review check config, not part of the build
|
|
'.agents/checks/eslint.strict.config.js',
|
|
// Devtools extensions, included dynamically
|
|
'tools/devtools/web/**'
|
|
],
|
|
vite: {
|
|
config: ['vite?(.*).config.mts']
|
|
},
|
|
vitest: {
|
|
config: ['vitest?(.*).config.ts'],
|
|
entry: [
|
|
'**/*.{bench,test,test-d,spec}.?(c|m)[jt]s?(x)',
|
|
'**/__mocks__/**/*.[jt]s?(x)'
|
|
]
|
|
},
|
|
playwright: {
|
|
config: ['playwright?(.*).config.ts'],
|
|
entry: ['**/*.@(spec|test).?(c|m)[jt]s?(x)', 'browser_tests/**/*.ts']
|
|
},
|
|
tags: [
|
|
'-knipIgnoreUnusedButUsedByCustomNodes',
|
|
'-knipIgnoreUnusedButUsedByVueNodesBranch',
|
|
'-knipIgnoreUsedByStackedPR'
|
|
]
|
|
}
|
|
|
|
export default config
|