-
Notifications
You must be signed in to change notification settings - Fork 19
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
refactor(demo): simplify the UseCase classes and how to set theme #564
Conversation
9b3a1d4
to
81b19df
Compare
81b19df
to
c5cea71
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.
ℹ️ I mainly check the features, less the code changes
Tested commit: c5cea71
✔️ monitoring
- with the UI use case and displayed information
- using query parameters https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/monitoring-all-process-instances/index.html?useCase=frequency&dataType=paths
✔️ prediction: all use cases are working
❌ hacktoberfest : default ko (others use cases are working: theme and year)
- default tab: not displayed and error in the console
- https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/hacktoberfest-custom-themes/index.html
- Firefox 118.0.2 (64 bits) on Ubuntu 20.04
14:34:59,117 Uncaught TypeError: this._bpmnVisualization is undefined
_displayVersionInfoInFooter https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/static/js/use-case.js:38
display https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/static/js/use-case.js:29
changeUseCase https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/hacktoberfest-custom-themes/js/index.js:19
oninput https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/c5cea71/demo/hacktoberfest-custom-themes/js/index.js:32
use-case.js:38:29
- Chrome 118.0.5993.70 (64 bits) on Ubuntu 20.04
use-case.js:38 Uncaught TypeError: Cannot read properties of undefined (reading 'getVersion')
at HacktoberfestUseCase._displayVersionInfoInFooter (use-case.js:38:53)
at HacktoberfestUseCase.display (use-case.js:29:14)
at changeUseCase (index.js:19:19)
at document.getElementById.onchange (index.js:37:5)
@@ -1,17 +1,21 @@ | |||
function buildUseCase(type, year, projectName) { | |||
switch (type) { | |||
function buildUseCase() { |
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.
praise: much clearer 👍🏿
if (themeElement.fontFamily) { | ||
style[StyleIdentifiers.STYLE_FONTFAMILY] = themeElement.fontFamily; | ||
} | ||
if (themeElement.fontSize) { | ||
style[StyleIdentifiers.STYLE_FONTSIZE] = themeElement.fontSize; | ||
} |
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.
praise: more consistent with the management of other properties
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.
✔️ Validated remaining fix with https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/44cb8a1/demo/hacktoberfest-custom-themes/index.html
Live environment of examples
https://cdn.statically.io/gh/process-analytics/bpmn-visualization-examples/refactor/use_cases_in_demos/examples/index.html