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

fix(editor): Fix hard-coded parameter names for code editors #6372

Merged
merged 3 commits into from
Jun 2, 2023

Conversation

MiloradFilipovic
Copy link
Contributor

As mentioned in the Linear ticket, our Vue components had hard-coded values for node properties that contain editor values (query, jsCode and html).
This PR fixes that by searching for node properties with appropriate editor set in typeOptions and uses found property name to extract it's value.

@MiloradFilipovic MiloradFilipovic self-assigned this Jun 2, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2023

Great PR! Please pay attention to the following items before merging:

Files matching packages/**:

  • If fixing bug, added test to cover scenario.
  • If addressing forum or Github issue, added link to description.

Files matching **/*.vue:

  • Used composition API for all new components.
  • Added component or unit tests to cover functionality.

Files matching packages/editor-ui/**/*.vue:

  • Added E2E if adding new features.
  • Used design system tokens (colors, spacings...) where possible.

Make sure to check off this list before asking for review.

@codecov
Copy link

codecov bot commented Jun 2, 2023

Codecov Report

Patch coverage: 20.00% and project coverage change: -0.09 ⚠️

Comparison is base (968b733) 28.33% compared to head (80413a6) 28.24%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6372      +/-   ##
==========================================
- Coverage   28.33%   28.24%   -0.09%     
==========================================
  Files        2982     2982              
  Lines      185187   185204      +17     
  Branches    20304    20298       -6     
==========================================
- Hits        52464    52308     -156     
- Misses     131936   132109     +173     
  Partials      787      787              
Impacted Files Coverage Δ
...ckages/editor-ui/src/components/ParameterInput.vue 57.53% <20.00%> (-0.67%) ⬇️

... and 6 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Member

@netroy netroy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 🙏🏽

@n8n-assistant n8n-assistant bot added n8n team Authored by the n8n team ui Enhancement in /editor-ui or /design-system labels Jun 2, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2023

⚠️ Some Cypress E2E specs are failing, please fix them before merging

@cypress
Copy link

cypress bot commented Jun 2, 2023

1 flaky tests on run #1088 ↗︎

0 228 0 0 Flakiness 1

Details:

🌳 NODE-572-editor-parameter-name-fix 🖥️ browsers:node18.12.0-chrome107 🤖 Milo...
Project: n8n Commit: 80413a6f1e
Status: Passed Duration: 47:51 💡
Started: Jun 2, 2023 4:16 PM Ended: Jun 2, 2023 5:04 PM
Flakiness  cypress/e2e/17-workflow-tags.cy.ts • 1 flaky test

View Output Video

Test Artifacts
Workflow tags > should detach a tag inline by clicking on X on tag pill Output Screenshots Video

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings.

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2023

✅ All Cypress E2E specs passed

@MiloradFilipovic MiloradFilipovic merged commit f61b776 into master Jun 2, 2023
@MiloradFilipovic MiloradFilipovic deleted the NODE-572-editor-parameter-name-fix branch June 2, 2023 17:04
MiloradFilipovic added a commit that referenced this pull request Jun 2, 2023
* master:
  fix(editor): Fix hard-coded parameter names for code editors (#6372)
  ci: Add support for Node.js 18 (#5793)
  ci: Update the release process for v1 release (#6366)
  refactor: Add deprecation notice for UM disabled mode (#6367)
  feat(editor): Make WF name a link on /executions (#6354)
  ci: Revert "Set up Turborepo cache for GitHub actions runner" (#6364) (no-changelog)
  fix(editor): Add secondary icon to menu items (#6351)
  fix(editor): Pin all data regardless of pagination (#6346)
  feat(Crypto Node): Add support for hash and hmac on binary data (#6359)
  ci: Set up Turborepo cache for GitHub actions runner (no-changelog) (#6335)

# Conflicts:
#	packages/editor-ui/src/components/ParameterInput.vue
@janober
Copy link
Member

janober commented Jun 14, 2023

Got released with n8n@0.232.0

netroy pushed a commit that referenced this pull request Jun 14, 2023
* fix(editor): Fix hard-coded parameter names for code editors
* ⚡ Adding computed property for editor content
* 👌 Refactoring based on the code review comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
n8n team Authored by the n8n team Released ui Enhancement in /editor-ui or /design-system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants