Commit Graph

29 Commits

Author SHA1 Message Date
balajisoundar
837d0cc76a
chore: custom widget (#28926)
## Description
This PR's adds the custom widget.

#### PR fixes following issue(s)
Fixes #28607
Fixes #28610
Fixes #28615
Fixes #28608
Fixes #28612
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
- New feature (non-breaking change which adds functionality)
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [ ] Manual
- [ ] JUnit
- [x] Jest
- [x] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [x] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Introduced search functionality with a wildcard option for unmatched
widget searches.
  - Added new routes for custom widget editing.
  - Implemented additional editor modes for HTML and CSS.
- Created new code templates and help components for custom widget
builders.
- Enhanced property controls with new button controls for custom widget
editing.
  - Updated theming interfaces and constants for better theming support.
- Added the CustomWidget component for embedding custom widgets in
iframes.
  - Expanded widgets library to include the CustomWidget.

- **Enhancements**
- Improved `CodeEditor` with additional modes, props, and resize
behavior.
- Enhanced `PropertyPaneControlConfig` interface with dynamic
dependencies and additional properties.
- Refined custom widget scripts with communication channel and event
handling.

- **Bug Fixes**
  - Fixed visibility logic for the `ExternalWidget` card.
  
- **Documentation**
- Added new messages and documentation links for custom widget features.

- **Tests**
- Implemented new Cypress tests for custom widget default components and
property pane interactions.
  - Updated workspace commands in Cypress tests.

- **Refactor**
- Streamlined `PropertyControl` state management and editing functions.
  - Refactored code editor hint helper logic.
  
- **Style**
  - Added `borderLess` prop to style components without borders.

- **Chores**
  - Updated constants and messages related to custom widget features.
  - Adjusted webpack configuration to ignore specific module warnings.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2023-12-28 12:16:28 +05:30
Hetu Nandu
ca1713c73e
fix: Improvements to Sidebar for navigation (#29205)
## Description

- Rename to Pages to Editor in the Sidebar
- Move Editor to top
- Update "Home" to "All apps"

#### PR fixes following issue(s)
Fixes #29206

#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
> Please delete options that are not relevant.
- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [ ] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [ ] 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
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed
2023-11-30 06:11:59 +05:30
Hetu Nandu
0cd9bc6922
refactor: Cypress SelectEntityByName (#29012)
Refactors SelectEntityByName to allow all types of selections but makes
defining the Entity Type compulsory
2023-11-23 15:46:13 +05:30
Aishwarya-U-R
e9a1f86e22
test: Cypress | CI Stablize + Other improvements (#28254)
## Description
**This PR does the below improvements:**
- Handles initial empty error toast- with cy.LogOut()
- Calling cy.LoginFromAPI() per need only - to improve execution time 
- Update agHelper.UpdateCodeInput()
- Added waitForNetworkCall for AsserHelper methods to only get api call
& validate
- Added gitSync.AuthorizeKeyToGitea() - to validate keyGenerate success
- Adding validationg for 'Unable to import application in workspace'
- cy.CreateNewAppInNewWorkspace() improved
- agHelper.RemoveUIElement() created to handle tooltip, toast,
evaluatedpopup & removed duplicates
- cy.merge() improved to call assertHelper
- assertHelper.AssertNetworkStatus() to handle both array & individual
status checks & return actual responseCode
- createBranch & generatedKey intercepts added to git operation
validations
- homePage.AssertApplication() created
- Removed cy.Logout() & Login improved - brings down total run time to
less than 1 hr from 1+ hrs
- entityExplorer.NavigateToSwitcher() improved to check status
- dataSources.ValidateDSDeletion() improved to handle one of array toast
for array value also
- assertHelper.WaitForNetworkCall() improved to wait & return latest
request
- Private methods processNetworkStatus() & processNetworkResponseData()
created
  
**Also flaky fixes below:**
- ServerSide/QueryPane/S3_2_spec.ts - Adding sleep for CI flaky
behaviour
- Trial fix for
cypress/e2e/Regression/ClientSide/OtherUIFeatures/PageOnLoad_spec.ts
- GitWithJSLibrary/GitwithCustomJSLibrary_spec.js - Handling Import
failure at various points in the flow
- ExplorerTests/Widgets_Copy_Paste_Delete_Undo_Keyboard_Event_spec.js
   - ClientSide/JSLibrary/Library_spec.ts - asserting success import
   - /OtherUIFeatures/ApplicationURL_spec.js - using cy.url()
   - /ClientSide/Templates/Fork_Template_spec.js
- ServerSide/Postgres_DataTypes/Binary_Spec.ts &
/Postgres_DataTypes/Json_Spec.ts - Adding sleep for CI flaky behaviour
   - ClientSide/Widgets/List/List4_2_spec.js
   - /Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-10-25 19:33:07 +05:30
Aishwarya-U-R
4ffc5bb62a
test: Cypress | CI Stabilize + Other test improvements (#28172)
## Description
- **This PR flaky fixes below specs:**
    - GenerateCRUD/MySQL2_Spec.ts script fix
   - ServerSide/ApiTests/API_All_Verb_spec.js
   - Regression/Apps/PromisesApp_spec.js
   - TableV2_Property_ToggleJs_With_Binding_spec.js
   - GSheet cases failures due to EditApponHover method fix
- Radio/Radio2_spec.ts, using `GetHeight` instead of
`GetWidgetCSSHeight`
   - Select/Select3_Spec.ts
   - Widgets/Text/Text_new_feature_spec.js
   - Binding/API_with_List_Widget_spec.js
   - Workspace/LoginFromUIApp_spec.js - removed redundant code
   - QueryPane/DSDocs_Spec.ts
   - ServerSide/QueryPane/GoogleSheets_spec.ts
   - TableV2/Date_column_editing_1_spec.ts
- Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts - script flow
corrected
   - ServerSide/QueryPane/Mongo_Spec.js
- **Added validation for form plugin response data, which addresses the
Empty toast issue**

- **Below specs are fixed for new appName localStorage changes:**
    - /SettingsPane/PageSettings_spec.ts
    - BugTests/Moment_Spec.ts
    - /Fork/ForkAppWithMultipleDS_Spec.ts
    - Fork/ForkApplicationWithinAppEditor_spec.ts
    - Fork/ForkApplication_spec.ts
    - /ClientSide/OtherUIFeatures/Analytics_spec.js
    - OtherUIFeatures/ApplicationURL_spec.js
    - OtherUIFeatures/ExportApplication_spec.js - Duplicate case removed
    - OtherUIFeatures/UpdateApplication_spec.js
    - VisualTests/JSEditorIndent_spec.js
    - Workspace/WorkspaceImportApplication_spec.js
 
- **Improvemnets:**
- deployMode.StubWindowNAssert() improved to validate `getPluginForm`
instead of `getWorkspace`
  - agHelper.AddDsl() improved, removed wait times
  - appSettings.CheckUrl() - appName url updated
  - assertHelper.AssertDocumentReady() -removed wait times
- assertHelper.AssertNetworkResponseData() - added for `getPluginForm`
validation for Page loads
  - deployMode.DeployApp() -removed wait times
- homePage.CreateNewWorkspace() - improved to set localStorage for
workspaceName, workspaceId & create new workspace without new name
- homePage.CreateNewApplication() - - improved to set localStorage for
appName
  - jsEditor.NavigateToNewJSEditor() - improved to remove tooltip
- cy.CreateAppInFirstListedWorkspace() - improved to set localStorage
for appName, removed waitTimes, Removed rename of every app for every
spec, calling AssertNetworkResponseData(getPluginForm)
  - cy.DeleteWorkspaceByApi() added
- e2e.js - removed guid generation for first app, added
cy.DeleteWorkspaceByApi() in after()
  
#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-10-20 07:45:47 +05:30
Aishwarya-U-R
61db723d35
test: Cypress | Firestore validations added + CI Stabilize (#27554)
## Description
- This PR adds below validation for firestore DS
- Firestore - Added documentation verification (added Staging dummy data
for Firestore DS)
  - Firestore - Added mandatory fields validations
  - Firestore - added placeholder validation
  - Firestore - Added widget binding & deploy app validation
  - Firestore - DS logo validation
- Flaky fix - Templates/Filtering/TemplatesModal_filtering_spec.ts
- CreateAppInFirstListedWorkspace() improved to navigate to New
Application edit page after creation
- Pin_Spec.js - updated validation for airgap
- Trial fix - ServerSide/Datasources/Oracle_Spec.ts
- Removing cypress/package.json as its not used

#### Type of change
- Script update (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

---------

Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
2023-09-25 20:02:54 +05:30
Aishwarya-U-R
0c8ed66d86
test: Cypress | CI Stabilize (#27493)
## Description
- This PR fixes the flaky /ClientSide/OtherUIFeatures/Omnibar_spec.js
- Removed added parameter from CreateDataSource()
- Fixed MsSQL to use same DS thruout
- Fix on StubWindowNAssert() to check the external link navigation
related issues
- using TS Refresh() in Onboarding.skipSignposting() + Added timeout for
#sidebar visibility to check app load empty toast issue
- Trial fix
cypress/e2e/Regression/ClientSide/Binding/Button_Text_WithRecaptcha_spec.js

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-09-21 00:41:08 +05:30
akash-codemonk
a0ba47c8ad
chore: Add more assertions to check editor loading state (#24772) 2023-06-27 13:50:54 +05:30
Aishwarya-U-R
91325d258e
test: Cypress | Moving Non-TED containers within Tests (#24709)
## Description
- This PR improves the container start for 
- Arango DB - Container started moved to test case level
- MsSql - Delete container added
- Elastic - Container started moved to test case level
- Starts container, runs tests, stops containers & deletes it too 🤞🏻
- Removed containers start from yml file
- Flaky fixes below:
         - Apps/ReconnectDatasource_spec.js
         - Improved FillPostgresDSForm()

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after all changes are reviewed
2023-06-21 23:07:21 +05:30
Aishwarya-U-R
d7b2bad974
test: Cypress | Cy 12 upgrade + Flaky fixes (#23852)
## Description
- This PR upgrades cypress from 11.2 to 12.13.0 which fixes the random
browser crash issue in CI runs
 - ValidateNetworkStatus() updates to validate the n/w responses
 - cy.route() to cy.intercept()
 - Converting dataSources.json to HostPort.ts
 - Api responses read - updating to right Cy12 supported format
- js inconsistent testJsontext to TS `EnterJSContext` in few failing
specs
 - CI - higher resolution trials
- Improves _.agHelper.RefreshPage() - fixing Error: Socket closed before
finished writing response
 - AssertDocumentReady() created
 - within(()) & .children() - handled for Cy12
- Improved DeployApp(), NavigateBacktoEditor(), RefreshPage(), AddDsl()
methods
- js inconsistent goToEditFromPublish to TS `NavigateBacktoEditor` in
all specs
- js inconsistent PublishtheApp to TS `_.agHelper.DeployApp` in all
specs
- Convert /DynamicHeight/Text_Widget_spec.js to TS with all supporting
TS helpers
 - ToggleJSMode()
 - COMMIT_INFO_MESSAGE improved
 - Remove tooltip on the Application Name after rename
- js inconsistent cy.addDsl(dsl); to TS helper `_.agHelper.AddDsl(val);`
 - ++++ Much more improvements....

#### Type of change
- Script fixes

## Testing
#### How Has This Been Tested?
- [X] Cypress

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

---------

Co-authored-by: Vijetha-Kaja <vijetha@appsmith.com>
2023-06-15 18:51:11 +05:30
Ankita Kinger
2ec6610399
chore: Updating locators for EE tests (#23563)
## Description

Updating locators for EE tests

#### PR fixes following issue(s)
Fixes # (issue number)
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
> Please delete options that are not relevant.
- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [ ] Manual
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [ ] 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
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Test-plan-implementation#speedbreaker-features-to-consider-for-every-change)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans/_edit#areas-of-interest)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed
2023-05-20 06:19:33 +05:30
albinAppsmith
629999f124
feat: [epic] appsmith design system version 2 deduplication (#22030)
## Description

### Fixes
- [x] https://github.com/appsmithorg/appsmith/issues/19383
- [x] https://github.com/appsmithorg/appsmith/issues/19384
- [x] https://github.com/appsmithorg/appsmith/issues/19385
- [x] https://github.com/appsmithorg/appsmith/issues/19386
- [x] https://github.com/appsmithorg/appsmith/issues/19387
- [x] https://github.com/appsmithorg/appsmith/issues/19388
- [x] https://github.com/appsmithorg/appsmith/issues/19389
- [x] https://github.com/appsmithorg/appsmith/issues/19390
- [x] https://github.com/appsmithorg/appsmith/issues/19391
- [x] https://github.com/appsmithorg/appsmith/issues/19392
- [x] https://github.com/appsmithorg/appsmith/issues/19393
- [x] https://github.com/appsmithorg/appsmith/issues/19394
- [x] https://github.com/appsmithorg/appsmith/issues/19395
- [x] https://github.com/appsmithorg/appsmith/issues/19396
- [x] https://github.com/appsmithorg/appsmith/issues/19397
- [x] https://github.com/appsmithorg/appsmith/issues/19398
- [x] https://github.com/appsmithorg/appsmith/issues/19399
- [x] https://github.com/appsmithorg/appsmith/issues/19400
- [x] https://github.com/appsmithorg/appsmith/issues/19401
- [x] https://github.com/appsmithorg/appsmith/issues/19402
- [x] https://github.com/appsmithorg/appsmith/issues/19403
- [x] https://github.com/appsmithorg/appsmith/issues/19404
- [x] https://github.com/appsmithorg/appsmith/issues/19405
- [x] https://github.com/appsmithorg/appsmith/issues/19406
- [x] https://github.com/appsmithorg/appsmith/issues/19407
- [x] https://github.com/appsmithorg/appsmith/issues/19408
- [x] https://github.com/appsmithorg/appsmith/issues/19409

Fixes # (issue)
> if no issue exists, please create an issue and ask the maintainers
about this first


Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video


## Type of change

> Please delete options that are not relevant.

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update


## How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Provide
instructions, so we can reproduce.
> Please also list any relevant details for your test configuration.
> Delete anything that is not important

- Manual
- Jest
- Cypress

### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [ ] 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
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Ankita Kinger <ankita@appsmith.com>
Co-authored-by: akash-codemonk <67054171+akash-codemonk@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvi@appsmith.com>
Co-authored-by: Arsalan <arsalanyaldram0211@outlook.com>
Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Rohit Agarwal <rohit_agarwal@live.in>
Co-authored-by: Nilesh Sarupriya <nilesh@appsmith.com>
Co-authored-by: Nilesh Sarupriya <20905988+nsarupr@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvibhakta@gmail.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
Co-authored-by: Vijetha-Kaja <vijetha@appsmith.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
Co-authored-by: Apple <nandan@thinkify.io>
Co-authored-by: Saroj <43822041+sarojsarab@users.noreply.github.com>
Co-authored-by: Sangeeth Sivan <74818788+berzerkeer@users.noreply.github.com>
Co-authored-by: Ashok Kumar M <35134347+marks0351@users.noreply.github.com>
Co-authored-by: Aishwarya-U-R <91450662+Aishwarya-U-R@users.noreply.github.com>
Co-authored-by: rahulramesha <rahul@appsmith.com>
Co-authored-by: Aswath K <aswath.sana@gmail.com>
Co-authored-by: Preet Sidhu <preetsidhu.bits@gmail.com>
Co-authored-by: Vijetha-Kaja <119562824+Vijetha-Kaja@users.noreply.github.com>
Co-authored-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2023-05-20 00:07:06 +05:30
akash-codemonk
bdab68c2ff
feat: signposting stickiness (#22088) 2023-05-02 15:22:05 +05:30
Ivan Akulov
424d2f6965
chore: upgrade to prettier v2 + enforce import types (#21013)Co-authored-by: Satish Gandham <hello@satishgandham.com> Co-authored-by: Satish Gandham <satish.iitg@gmail.com>
## Description

This PR upgrades Prettier to v2 + enforces TypeScript’s [`import
type`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-8.html#type-only-imports-and-export)
syntax where applicable. It’s submitted as a separate PR so we can merge
it easily.

As a part of this PR, we reformat the codebase heavily:
- add `import type` everywhere where it’s required, and
- re-format the code to account for Prettier 2’s breaking changes:
https://prettier.io/blog/2020/03/21/2.0.0.html#breaking-changes

This PR is submitted against `release` to make sure all new code by team
members will adhere to new formatting standards, and we’ll have fewer
conflicts when merging `bundle-optimizations` into `release`. (I’ll
merge `release` back into `bundle-optimizations` once this PR is
merged.)

### Why is this needed?

This PR is needed because, for the Lodash optimization from
7cbb12af88,
we need to use `import type`. Otherwise, `babel-plugin-lodash` complains
that `LoDashStatic` is not a lodash function.

However, just using `import type` in the current codebase will give you
this:

<img width="962" alt="Screenshot 2023-03-08 at 17 45 59"
src="https://user-images.githubusercontent.com/2953267/223775744-407afa0c-e8b9-44a1-90f9-b879348da57f.png">

That’s because Prettier 1 can’t parse `import type` at all. To parse it,
we need to upgrade to Prettier 2.

### Why enforce `import type`?

Apart from just enabling `import type` support, this PR enforces
specifying `import type` everywhere it’s needed. (Developers will get
immediate TypeScript and ESLint errors when they forget to do so.)

I’m doing this because I believe `import type` improves DX and makes
refactorings easier.

Let’s say you had a few imports like below. Can you tell which of these
imports will increase the bundle size? (Tip: it’s not all of them!)

```ts
// app/client/src/workers/Linting/utils.ts
import { Position } from "codemirror";
import { LintError as JSHintError, LintOptions } from "jshint";
import { get, isEmpty, isNumber, keys, last, set } from "lodash";
```

It’s pretty hard, right?

What about now?

```ts
// app/client/src/workers/Linting/utils.ts
import type { Position } from "codemirror";
import type { LintError as JSHintError, LintOptions } from "jshint";
import { get, isEmpty, isNumber, keys, last, set } from "lodash";
```

Now, it’s clear that only `lodash` will be bundled.

This helps developers to see which imports are problematic, but it
_also_ helps with refactorings. Now, if you want to see where
`codemirror` is bundled, you can just grep for `import \{.*\} from
"codemirror"` – and you won’t get any type-only imports.

This also helps (some) bundlers. Upon transpiling, TypeScript erases
type-only imports completely. In some environment (not ours), this makes
the bundle smaller, as the bundler doesn’t need to bundle type-only
imports anymore.

## Type of change

- Chore (housekeeping or task changes that don't impact user perception)


## How Has This Been Tested?

This was tested to not break the build.

### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [x] 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
- [x] 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
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Satish Gandham <hello@satishgandham.com>
Co-authored-by: Satish Gandham <satish.iitg@gmail.com>
2023-03-16 17:11:47 +05:30
Vijetha-Kaja
27dd208a3d
test: Flaky test fix (#20950)
## Description

**Fixed below flaky tests**
- Button_onClickAction_spec.js
- DeleteWorkspace_spec.js
- LeaveWorkspaceTest_spec.js
- WorkspaceSettings_validation_spec.js
- MongoDBShoppingCart_spec.js
- GitImport_spec.js
- Basic_spec.js

## Type of change

- Flaky test fix

## How Has This Been Tested?
- Cypress test runs

## Checklist:
### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-02-24 22:41:25 +05:30
Rishabh Rathod
f846122a37
chore: remove unnecessary skeleton component (#20645)
## Description

Remove unnecessary skeleton for the static UI in the home page's Left
pane.

Media

https://user-images.githubusercontent.com/23132741/219005309-76226c00-e433-4b0e-a796-f1ce0f578b33.mov


## Type of change

- Chore


## How Has This Been Tested?

- Manual


### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [ ] 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
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-02-22 12:32:43 +05:30
akash-codemonk
553a15ced9
feat: in-app embed settings (#19023)
## Description

Get code snippet for embedding
2022-12-26 10:41:33 +05:30
rahulramesha
3bb9e96e39
feat: [Context Switching] Complex widgets and other Phase 2 items (#17046)
This PR contains changes to retain context on the following items,
Leaving and then returning to a page should maintain what api/query was open
Entity explorer should stay as you left it when you left the page (collapse levels)
Widget/explorer tab
Width - Should be the same across all pages of an app
Property Pane width
Complex widgets, multi tier property panes

Co-authored-by: hetunandu <hetunandu@gmail.com>
Co-authored-by: Akash N <akash@codemonk.in>
Co-authored-by: Hetu Nandu <hetu@appsmith.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-12-08 12:51:58 +05:30
Parthvi
c4d6845bd5
test: Add cypress tests for leave workspace flow (#17354)
* Add leave workspace tests

* removing .pause()

* refactor test
2022-10-13 12:14:39 +00:00
akash-codemonk
a560051d86
feat: fork templates inside an existing app (#17184) 2022-09-30 19:11:04 +05:30
akash-codemonk
9715bd3db3
chore: Revert "feat: fork templates inside an existing app (#14514)" (#17041) 2022-09-26 13:44:39 +05:30
akash-codemonk
1b43b16461
feat: fork templates inside an existing app (#14514) 2022-09-22 09:19:18 +05:30
Aishwarya-U-R
bf232dbb7e
test: Script updates for flaky tests (#16558) 2022-09-07 23:55:55 +05:30
Aishwarya-U-R
f2c6e1ed61
test: Script updates for flaky fixes (#16143)
* Remove mongo coll dataset

* JSEXe spec flaky trial fix

* AbortActions to ts

* js func exe fix

* Abort spec fix

* Appsmith down flaky fix

* SelectWidget bug 12531 comment

* JSfun exec spec flaky fix

* Scrolling spec fix

* mysql crud fix

* mySql crud fix

* CRUD generate page fix

* jsonload flaky fix

* Automcomplete spec update

* jsOnload-1 spec flaky fix

* http patch

* patch install

* patch path correction

* cypress instal force

* removed

* yarn

* adding dev

* applypatch path corrected

* patch fix

* patch update

* patches

* patch file name update

* Adding blureprint patch back

* Cypress install removed

* Removed .only

* Autocomplete + Abort spec fix

* CI run key press fix

* https proxy update path fix

* JS editor parsing delay handle

* Autocmplete js fix

* Abort Query added

* Removed  "dev": "cypress open"

* js func exec spec fix

* js editor type flaky fix

* GetNClick revert

* Saving JS editor aft removal

* JS specs flaky fixes

* JSfun flaky fix

* Auto complete spec fi

* jSonkoad1 spec fix

* JSOnload spec

* Auto complete JS spec fix

* Removing waiting for toasts

* jsfun fix

* EditJSObj Preetify update

* contains index or colection

* SetQueryTimeout update

* DS toasts handle

* POstgresCRUD toast change

* POstgres CRUD toasts fix

* Bug 15372 spec toast fix + Api timeout update

* Added DeleteDSDirectly()

* Arango spec fix

* JSEditor indent spec - 6 fix

* JSeditor indent spec update 7, 1,2

* removed only

* JSEDitor Indent spec fixes

* removed only

* MySQK CRUD fixes

* BUg 14006 spec fix

* Mongo spec toast fix

* Mongo update

* text wrapping spec flaky fix
2022-08-24 19:53:41 +05:30
Trisha Anand
8f3591615a
feat: RBAC framework (#14823)
Co-authored-by: Sidhant Goel <sidhant@appsmith.com>
Co-authored-by: Ankita Kinger <ankita@appsmith.com>
Co-authored-by: Sangeeth Sivan <sangeeth@appsmith.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
2022-08-22 23:27:07 +05:30
Ankita Kinger
3933f5f4d1
feat: migrate from org to workspace under phase 3 (#14158)
* migration from organization to workspace on code level

* updated a few more files

* fixed runtime errors

* update org settings URL

* Renamed organizationId in domain objects

* changed field named from organization to workspace

* Reverted AppsmithRole changes

* fixed migrations

* recreating indexes

* migration update

* seed data runs before migration, undo changes

* mock commit

* seedmongo to populate upgraded data, datasource upgrade

* fixed two test cases

* updated migrations

* updated prop name

* Upgraded AclPermission

* comment

* migrated AppsmithRole

* more changes

* final set of changes

* variable name changes

* update cypress variable name

* Update app/server/appsmith-server/src/main/java/com/appsmith/server/controllers/ce/ApplicationControllerCE.java

* Update app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Datasource.java

Co-authored-by: Trisha Anand <trisha@appsmith.com>

* reverting encryption handler change

* refactor code to migrate from org to workspace

* migrated a few missed out org to workspace

* updated a few more

* migrated a few missed out org to workspace

* migration changes

* Removed Permission import

* reverted code change

* few more changes

* fixed failing cypress test

* fixed failing cypress test

Co-authored-by: Sidhant Goel <sidhant@appsmith.com>
Co-authored-by: Trisha Anand <trisha@appsmith.com>
Co-authored-by: Sidhant Goel <sidhant@hexcod.in>
2022-07-20 17:24:16 +05:30
Hetu Nandu
5d568b7a6f
fix: Tooltip for long names in Entity Explorer (#15068) 2022-07-20 06:06:11 +00:00
Aishwarya-U-R
5d75a46df1
test: Automated tests for Bug #14299 + Specs rearranged (#14632)
* Moving tests

* Workspace cases moved all to one folder

* Moving tests

* Bug 14299 scripted

* JSOnload spec failure fix

* Moving spec

* Moving specs

* Moving specs

* Added bug id in title

* Moving specs

* Moving specs

* Moving spec

* Added bug id in title

* Removed tests

* Theme Basic spec - added publish mode validations

* tests re-arranged

* Theme_form widget fix

* endp to endpoint change

* theme Basic spec fix

* AppSetupForRename removed

* Appli rename reverted

* Specs rearranged

* Added interval validation

* Also deleting query

* validation moved places

* Git imports corrected

* git import corrected

* datePicker fix
2022-06-23 20:43:15 +05:30
Ankita Kinger
9b7944e7ee
feat: migrate organisation to workspace (#13863)
* migration from organization to workspace on code level

* updated a few more files

* fixed runtime errors

* update org settings URL

* Renamed organizationId in domain objects

* changed field named from organization to workspace

* Reverted AppsmithRole changes

* fixed migrations

* recreating indexes

* migration update

* seed data runs before migration, undo changes

* mock commit

* seedmongo to populate upgraded data, datasource upgrade

* fixed two test cases

* updated migrations

* updated prop name

* Upgraded AclPermission

* comment

* migrated AppsmithRole

* more changes

* final set of changes

* variable name changes

* update cypress variable name

* Update app/server/appsmith-server/src/main/java/com/appsmith/server/controllers/ce/ApplicationControllerCE.java

* Update app/server/appsmith-interfaces/src/main/java/com/appsmith/external/models/Datasource.java

Co-authored-by: Trisha Anand <trisha@appsmith.com>

* reverting encryption handler change

* migrated a few missed out org to workspace

* migrated a few missed out org to workspace

* migration changes

* Removed Permission import

* fixed AppsmithRole

* mongodb version update

* fixed compile error

* fixed compile issue

* fixed some tests

* simplified embedded mongodb config

* updated a cypress test

Co-authored-by: Sidhant Goel <sidhant@appsmith.com>
Co-authored-by: Trisha Anand <trisha@appsmith.com>
Co-authored-by: Sidhant Goel <sidhant@hexcod.in>
2022-06-15 21:07:41 +05:30