-
Notifications
You must be signed in to change notification settings - Fork 658
Diagram Demos - Fix typeExpr implementation #31890
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
base: 25_2
Are you sure you want to change the base?
Diagram Demos - Fix typeExpr implementation #31890
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR updates the itemTypeExpr implementation across all framework variants (jQuery, Vue, React, ReactJs, Angular) of the Diagram "CustomShapesWithTemplatesWithEditing" demo. The change converts the function from a simple getter (return 'employee') to a bidirectional getter/setter pattern that can both read and write the type property of diagram nodes.
Key Changes:
- Added two-parameter signature
(obj, value)to support both getting and setting operations - Added setter logic to assign
valuetoobj.typewhen a value is provided - Returns
nullfor setter operations and'employee'for getter operations
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/jQuery/index.js | Updated typeExpr from simple getter to getter/setter with conditional logic |
| apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/Vue/App.vue | Updated itemTypeExpr arrow function from simple getter to getter/setter |
| apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/ReactJs/App.js | Updated itemTypeExpr function from simple getter to getter/setter |
| apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/React/App.tsx | Updated itemTypeExpr function from simple getter to getter/setter |
| apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/Angular/app/app.component.ts | Updated itemTypeExpr method from simple getter to getter/setter |
apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/jQuery/index.js
Outdated
Show resolved
Hide resolved
apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/Vue/App.vue
Outdated
Show resolved
Hide resolved
apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/ReactJs/App.js
Outdated
Show resolved
Hide resolved
apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/React/App.tsx
Outdated
Show resolved
Hide resolved
apps/demos/Demos/Diagram/CustomShapesWithTemplatesWithEditing/Angular/app/app.component.ts
Outdated
Show resolved
Hide resolved
e027eb1 to
62bb9bb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 6 comments.
apps/demos/Demos/Diagram/CustomShapesWithTemplates/Angular/app/app.component.ts
Show resolved
Hide resolved
cf11760 to
0c3c229
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.
apps/demos/Demos/Diagram/CustomShapesWithTemplates/Angular/app/app.component.ts
Show resolved
Hide resolved
0c3c229 to
7813d15
Compare
No description provided.