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: fixes apiEditor url overflow, indicates active datasource in datasour… #10663

Merged
merged 12 commits into from
Feb 11, 2022

Conversation

Irongade
Copy link
Contributor

@Irongade Irongade commented Jan 26, 2022

Prior to this PR:

  1. The Api Editor's url input introduces a scroll inside the input field when the text overflows to the next line causing the first line to be unreadable.
  2. It was difficult to identify the datasource of the action being used in the Api Editor.

This PR addresses the issues by

  1. Increasing the size of the focused input field when the text goes to the next line.
  2. Sorts the Datasources list such that the current action's datasource is displayed first and a "In use" tag is attached to it.

This PR also adds peformance optimizations for the ApiEditorForm and the EmbeddedDatasourcePathField components.
Fixes #6215

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • This change requires a documentation update

Manual tests.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Test coverage results 🧪

🔴 Total coverage has decreased
// Code coverage diff between base branch:release and head branch: fix/fix-apiEditor-ui-issues 
Status File % Stmts % Branch % Funcs % Lines
🔴 total 55.44 (-0.02) 37 (-0.06) 35.29 (-0.03) 55.82 (-0.02)
🔴 app/client/src/components/editorComponents/CodeEditor/codeEditorUtils.ts 73.85 (-21.8) 55.88 (-39.12) 55.56 (-15.87) 78.43 (-16.57)
🔴 app/client/src/components/editorComponents/CodeEditor/index.tsx 78.51 (-0.52) 60.48 (-1.28) 64.44 (-1.47) 80.13 (-0.6)
🔴 app/client/src/components/editorComponents/CodeEditor/styledComponents.ts 87.93 (0.21) 70.37 (-2.36) 100 (0) 89.29 (0.2)
🔴 app/client/src/components/editorComponents/form/fields/EmbeddedDatasourcePathField.tsx 28.89 (-0.38) 3.01 (1.03) 3.23 (-0.34) 30.72 (-0.82)
🟢 app/client/src/pages/Editor/APIEditor/ApiRightPane.tsx 44.29 (2.1) 44 (-1) 0 (0) 47.62 (2.01)
🔴 app/client/src/pages/Editor/APIEditor/Form.tsx 37.36 (-0.21) 36.84 (0) 0 (0) 39.08 (-0.23)
🔴 app/client/src/pages/Editor/APIEditor/helpers.ts 41.67 (-33.33) 0 (-100) 0 (0) 30 (-36.67)
🟢 app/client/src/selectors/commentsSelectors.ts 85.25 (1.64) 64.71 (2.95) 73.33 (0) 90.59 (2.35)
🔴 app/client/src/selectors/entitiesSelector.ts 46.85 (-0.1) 8.53 (0) 25.87 (-0.37) 43.51 (-0.1)

@vercel
Copy link

vercel bot commented Jan 26, 2022

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/get-appsmith/appsmith/4FGhybQgV3Z8UitmHiwHvGLvVWZa
✅ Preview: https://appsmith-git-fix-fix-apieditor-ui-issues-get-appsmith.vercel.app

@github-actions github-actions bot added the Bug Something isn't working label Jan 26, 2022
@github-actions
Copy link

Unable to find test scripts. Please add necessary tests to the PR.

@Irongade
Copy link
Contributor Author

/ok-to-test sha=673b4f2

@github-actions
Copy link

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1752303907.
Workflow: Appsmith External Integration Test Workflow.
Commit: 673b4f2.
PR: 10663.

@github-actions
Copy link

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1752303907.
Commit: 673b4f2.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Mean SD.Sample SD.Population
Edit input
scripting 456.49 395.04 366.26 415.05 498.52 426.27 12.21 10.92
painting 12.35 22.45 11.34 32.52 21.98 20.13 43.02 38.50
rendering 44.05 31.43 14.56 28.22 21.74 28 39.50 35.32
Clear input
scripting 985.17 1172.61 945.17 1004.75 985.6 1018.66 8.71 7.79
painting 12.46 9.11 11.46 21.84 14.37 13.85 35.02 31.34
rendering 342.95 302.18 312.36 354.04 313.35 324.98 6.85 6.13
Edit input again
scripting 769.2 322.6 416.21 424.73 365.61 459.67 38.70 34.61
painting 8.58 5.95 9 30.62 9.73 12.78 78.87 70.50
rendering 23.76 18.31 30.87 26.43 22.95 24.46 18.89 16.93

@Irongade
Copy link
Contributor Author

/ok-to-test sha=f71738a

@github-actions
Copy link

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1752831705.
Workflow: Appsmith External Integration Test Workflow.
Commit: f71738a.
PR: 10663.

@github-actions
Copy link

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1752831705.
Commit: f71738a.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Mean SD.Sample SD.Population
Click on table row
scripting 2608.28 2017.9 1990.25 2045.91 2227.9 2178.05 11.84 10.59
painting 23.05 14.12 18.74 23.53 25.75 21.04 22.01 19.68
rendering 481.19 298.07 311.38 310.62 342.83 348.82 21.74 19.44
Edit input
scripting 300.1 366.01 276.99 319.22 266.65 305.79 12.87 11.52
painting 7.92 9.48 15.4 7.93 5.36 9.22 40.78 36.44
rendering 14.96 19.31 16.88 24.09 14.67 17.98 21.64 19.35
Clear input
scripting 828.42 881.91 786.05 807.58 904.77 841.75 5.95 5.32
painting 19.56 12.44 16.99 16.1 10.42 15.1 24.24 21.66
rendering 232.41 232.2 226.94 241 206.77 227.86 5.63 5.03
Edit input again
scripting 330.01 289.68 280.98 320.15 294.74 303.11 6.91 6.18
painting 8.45 11.55 12.56 5.14 7.16 8.97 34.23 30.66
rendering 27.96 17.34 22.92 21.81 29.17 23.84 20.18 18.04

@Irongade Irongade changed the title fix: fixes apiEditor url overflow, indicates active datasource in datasour… fi: fixes apiEditor url overflow, indicates active datasource in datasour… Jan 26, 2022
@Irongade Irongade changed the title fi: fixes apiEditor url overflow, indicates active datasource in datasour… fix: fixes apiEditor url overflow, indicates active datasource in datasour… Jan 26, 2022
@github-actions github-actions bot removed the Bug Something isn't working label Jan 26, 2022
@github-actions
Copy link

Unable to find test scripts. Please add necessary tests to the PR.

@github-actions github-actions bot added the Bug Something isn't working label Jan 26, 2022
@github-actions
Copy link

Unable to find test scripts. Please add necessary tests to the PR.

@Irongade
Copy link
Contributor Author

Irongade commented Feb 1, 2022

/ok-to-test sha=55b0900

@github-actions
Copy link

github-actions bot commented Feb 1, 2022

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1778248874.
Workflow: Appsmith External Integration Test Workflow.
Commit: 55b0900.
PR: 10663.

@Irongade Irongade requested review from ayushpahwa and removed request for AmanAgarwal041 February 1, 2022 12:54
@github-actions
Copy link

github-actions bot commented Feb 1, 2022

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1778248874.
Commit: 55b0900.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Mean SD.Sample SD.Population
Click on table row
scripting 2817.8 2160.61 2137.66 2156.69 2126.78 2279.91 13.20 11.81
painting 28.83 13.87 15.87 12.63 12.49 16.74 41.16 36.86
rendering 375.12 260.01 228.59 265.19 253.6 276.5 20.58 18.40
Edit input
scripting 303.61 304.78 308.46 292.08 275.8 296.95 4.49 4.01
painting 10.16 4.62 11.63 4.28 3.54 6.85 54.74 49.05
rendering 28.35 19.23 17.05 13.86 11.33 17.96 36.41 32.57
Clear input
scripting 722.95 761.35 798.04 731.8 750.3 752.89 3.90 3.49
painting 5.67 13.47 9.46 10.39 17.75 11.35 39.91 35.68
rendering 172.22 198.46 188.77 180.82 223.01 192.66 10.14 9.07
Edit input again
scripting 264.36 283.21 285.38 299.4 640.01 354.47 45.17 40.40
painting 16.07 10.46 7.45 5.28 4.7 8.79 52.90 47.33
rendering 17.27 17.47 15.35 20.58 18.71 17.88 10.79 9.68

@github-actions
Copy link

github-actions bot commented Feb 4, 2022

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1792643432.
Commit: 665b3b3.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Median Mean SD.Sample SD.Population
Click on table row
scripting 3267.32 2564.63 2580.16 2604.13 2585.64 2585.64 2720.38 11.25 10.06
painting 51.87 10.93 25.23 21.46 9.03 21.46 23.7 72.45 64.81
rendering 452.84 315.08 278.11 292.54 296.66 296.66 327.05 21.88 19.57
Edit input
scripting 330.62 402.86 332.33 352.45 396.32 352.45 362.92 9.54 8.54
painting 32.59 19.61 11.77 4.36 15.17 15.17 16.7 62.81 56.17
rendering 13.83 21.49 17.21 14.69 18.5 17.21 17.14 17.91 16.04
Clear input
scripting 857.93 875.8 885.27 918.84 886.14 885.27 884.8 2.50 2.24
painting 6.06 10.34 6.09 8.28 6.43 6.43 7.44 25.00 22.45
rendering 202.61 219.95 209.7 210.7 203.77 209.7 209.35 3.30 2.95
Edit input again
scripting 798.95 311.85 326.8 369.62 403.01 369.62 442.05 45.86 41.02
painting 18.32 11.18 5.36 8.32 8.84 8.84 10.4 47.02 42.02
rendering 21.54 22.03 20.25 23.13 20.52 21.54 21.49 5.44 4.89

@github-actions
Copy link

github-actions bot commented Feb 7, 2022

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1808248361.
Workflow: Appsmith External Integration Test Workflow.
Commit: c74c6b9.
PR: 10663.

@Irongade
Copy link
Contributor Author

Irongade commented Feb 7, 2022

/ok-to-test sha=6a179ef

@github-actions
Copy link

github-actions bot commented Feb 7, 2022

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1808268571.
Workflow: Appsmith External Integration Test Workflow.
Commit: 6a179ef.
PR: 10663.

@github-actions
Copy link

github-actions bot commented Feb 7, 2022

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1808248361.
Commit: c74c6b9.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Median Mean SD.Sample SD.Population
Click on table row
scripting 2582.33 2184.09 2166.42 2311.9 2220.92 2220.92 2293.13 7.46 6.68
painting 73.63 34.4 13.55 18.91 15.01 18.91 31.1 80.96 72.41
rendering 423.3 274.85 313.13 284.89 264.38 284.89 312.11 20.75 18.56
Edit input
scripting 355.13 343.97 350.92 336.11 413.65 350.92 359.96 8.58 7.67
painting 9.35 5.39 9.58 20.79 16.33 9.58 12.29 50.20 44.91
rendering 16.66 15.93 17.39 20.79 22.5 17.39 18.65 15.23 13.62
Clear input
scripting 776.45 782.94 764.21 973.82 787.24 782.94 816.93 10.79 9.65
painting 11.87 6.45 6.09 7.68 6.41 6.45 7.7 31.30 27.92
rendering 187.23 197.09 193.34 183.78 186.1 187.23 189.51 2.91 2.61
Edit input again
scripting 332.82 324.68 290.06 352.1 324.96 324.96 324.92 6.91 6.18
painting 17.31 12.33 6.01 14.68 4.73 12.33 11.01 49.59 44.41
rendering 26.32 19.97 21.78 23.52 19.79 21.78 22.28 12.21 10.91

@github-actions
Copy link

github-actions bot commented Feb 8, 2022

UI Performance test run logs and artifacts: https://github.com/appsmithorg/appsmith/actions/runs/1808268571.
Commit: 6a179ef.
Results:

Click to view performance test results

Run 1 Run 2 Run 3 Run 4 Run 5 Median Mean SD.Sample SD.Population
Click on table row
scripting 2126.37 2197.83 2941.39 2213.19 2211.93 2211.93 2338.14 14.50 12.97
painting 11.93 16.89 49.68 14.39 37.59 16.89 26.1 63.83 57.09
rendering 317.51 256.92 361.69 239.34 256 256.92 286.29 18.02 16.12
Edit input
scripting 314.86 305.28 261.14 1349.95 270.2 305.28 500.29 95.05 85.01
painting 7.31 5.17 5.24 6.07 4.07 5.24 5.57 21.54 19.39
rendering 19.05 16.86 14 14.36 12.32 14.36 15.32 17.23 15.40
Clear input
scripting 741.69 743.12 722.22 757.87 786.75 743.12 750.33 3.20 2.86
painting 7.27 5.1 6.49 5.7 6.93 6.49 6.3 14.13 12.70
rendering 199.98 177.36 169.23 181 186.4 181 182.79 6.27 5.61
Edit input again
scripting 305.4 302.68 356.57 356.19 311.92 311.92 326.55 8.40 7.51
painting 14.67 7.7 9.67 21.37 7.86 9.67 12.25 47.51 42.53
rendering 24.27 19.48 20.78 20.47 18.89 20.47 20.78 10.06 9.00

@Irongade Irongade changed the title fix: fixes apiEditor url overflow, indicates active datasource in datasour… fi: fixes apiEditor url overflow, indicates active datasource in datasour… Feb 8, 2022
@Irongade Irongade changed the title fi: fixes apiEditor url overflow, indicates active datasource in datasour… fix: fixes apiEditor url overflow, indicates active datasource in datasour… Feb 8, 2022
@github-actions github-actions bot removed the Bug Something isn't working label Feb 8, 2022
@github-actions
Copy link

github-actions bot commented Feb 8, 2022

Unable to find test scripts. Please add necessary tests to the PR.

@github-actions github-actions bot added the Bug Something isn't working label Feb 8, 2022
@github-actions
Copy link

github-actions bot commented Feb 8, 2022

Unable to find test scripts. Please add necessary tests to the PR.

@prapullac
Copy link
Contributor

prapullac commented Feb 10, 2022

Issue related to PR :

  1. On trying to navigate back from the empty Authenticated API page the app breaks
    Steps to reproduce:
  2. Create a new application
  3. Navigate to "New API" from Entity explorer
  4. Have a blank API
  5. Click on "Authentication" Tab
  6. Click on Save Datasource
  7. Click Multiple times on "Delete" option
  8. Click on "Back" button
    and observe that the application breaks

@hetunandu hetunandu removed their request for review February 10, 2022 08:30
@Irongade
Copy link
Contributor Author

Irongade commented Feb 10, 2022

Issue related to PR :

  1. On trying to navigate back from the empty Authenticated API page the app breaks

I'm sorry I cant seem to reproduce this bug. Neither could Aman or Nidhi.

@Irongade
Copy link
Contributor Author

/ok-to-test sha=3f9b68c

@github-actions
Copy link

Tests running at: https://github.com/appsmithorg/appsmith/actions/runs/1826907734.
Workflow: Appsmith External Integration Test Workflow.
Commit: 3f9b68c.
PR: 10663.

@rohan-arthur rohan-arthur added the BE Coders Pod Issues related to users writing code to fetch and update data label Feb 11, 2022
@Irongade Irongade merged commit 44ce1d4 into release Feb 11, 2022
@Irongade Irongade deleted the fix/fix-apiEditor-ui-issues branch February 11, 2022 11:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BE Coders Pod Issues related to users writing code to fetch and update data Bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] Indicate active datasource in the datasources pane
4 participants