Commit Graph

136 Commits

Author SHA1 Message Date
arunvjn
2dc7dc90e3
feat: Import javascript libraries (#17895) 2022-12-21 22:44:47 +05:30
Aman Agarwal
4a381607eb
fix: google sheet ui issues, removed redundant code (#18785)
Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2022-12-20 20:40:18 +05:30
Aswath K
c72f865962
chore: Property pane search input focus (#18858) 2022-12-15 16:25:52 +05:30
Ayangade Adeoluwa
2cc64183c8
fix: Error handling for undefined datasource in API Authentication (#18881) 2022-12-13 17:16:56 +05:30
Anand Srinivasan
284571803b
fix: update settings pane validations (#18739)
* init fix

* button style update

* decode url in preview

* bring back custom slug validation

* custom slug validation on type

* remove imports

* handle special characters in url preview

* change label

* code clean up

* remove pageId from action name selector

* messages clean up

* tests for validations

* cypress cases update

* Renamed helper methods

* add index for test cases

* AppSettings specs script ts updates

* Added Bud id in title #18698

* GIt Import spec fix

* GItImport spec fix

* Git import unskip

* Skipping Git import

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-12-12 10:21:14 +05:30
Aswath K
ce2925cafc
feat: Property pane search (#18164) 2022-12-11 20:12:32 +05:30
Ankita Kinger
d9f20e33ad
chore: splitting the role name to avoid showing workspace name next to it (#18830)
* splitting the role name to avoid showing workspace name next to it

* fixing cypress tests failures
2022-12-10 14:00:28 +05:30
Aishwarya-U-R
70f6cd1ab8
test: Automated tests for Bug18376 + few flaky fixes (#18769)
* ApiOnload spec fix

* Bug 18376 script added

* Bug 18376 script fix

* ValidateURL() added

* OnLoadTests/APIOnLoad_Spec.ts fix

* Moved Bug 16248 script

* JSOnload trial fix

* JsonLoad fix -disbaling not working hnce commented

* Skipping GitImport (merge issue-open bug 18776)

* Git imPort trial fix

* PassingParams spec update

* APIPage.ts wrong update corrected

* Removed added comments

* ApiPage.ts mistake corrected!
2022-12-09 10:36:52 +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
akash-codemonk
3eab587368
feat: [Context Switching] Maintain datasource collapse state (#17616) 2022-12-05 11:28:17 +05:30
Anand Srinivasan
c01ed28189
feat: New settings pane (#16361) 2022-12-02 11:19:51 +05:30
akash-codemonk
89bf555727
feat: [ Context Switching ] Maintain datasource edit mode (#17521) 2022-12-02 08:36:22 +05:30
sneha122
b5902bf035
feat: Datasource autosave improvements (#17649)
* Datasource autosave improvements WIP

* authenticated API and ds name updates

* popup updates, api to datasource updates

* issue fixes for new ds in new workspace

* formatter issue fixed

* console warning issue fixed

* refresh edge case handled for temp ds

* DS creation cypress update

* datasource improvements issue fixes

* CreateDS flow change cypress update

* reconnect issue fixed

* added space

* Create Ds related script updates

* SaveDs changes updated

* DatasourceForm_spec.js fix

* GoogleSheetsQuery_spec.js - still spec will fail

* GoogleSheetsStub_spec.ts fix

* MongoDatasource_spec.js fix

* ElasticSearchDatasource_spec.js fix

* AuthenticatedApiDatasource_spec.js

* RestApiDatasource_spec.js - will stil fail

* RedshiftDataSourceStub_spec.js fix

* issue fixes for datasource autosave

* save as datasource issue fixed

* SKipped - Bug 18035

* MySQL spec fix

* PostgresDatasource_spec.js fix

* MySQLDataSourceStub_spec.js fix

* MsSQLDataSourceStub_spec.js fix

* Bug16702_Spec.ts fix

* SwitchDatasource_spec.js fix

* ArangoDataSourceStub_spec.js fix

* code review changes, save and authorise issue fixed

* cypress test issue and cypress tests fixed

* client build failure issue fixed

* test failure fixes

* ReconnectDatasource_spec.js fix

* Entity_Explorer_CopyQuery_RenameDatasource_spec.js fix

* GitImport_spec.js fix

* Index add

* undo redo test issue fixed

* fixed cypress tests of rest api ds

* globalsearch_spec.js fixed

* code review changes

* code review comments addressed

* ds schema cypress issue fixed

* cypress test updates

* fix updateDatasource path

* rest api cypress test fixed

* cypress code review changes

* Removing few random .only's

* replay editor fix

* indexed

* adding .skip

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-11-30 11:29:45 +05:30
sneha122
03eaab7c58
fix: gsheet save and authorize redirect issue fixed (#18389)
* gsheet save and authorize redirect issue fixed

* cypress test code review issue fixed

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2022-11-28 10:42:27 +05:30
ChandanBalajiBP
14ea007ad4
fix: Refresh datasource structure on save (#18290)
* fix: Refresh datasource structure on save

* added test case

* update for test failing on release
2022-11-25 08:05:37 +03:00
akash-codemonk
61dfe14f4f
chore: Context switching - Api right pane tabs (#17473) 2022-11-25 09:17:00 +05:30
Aishwarya-U-R
20504beae4
test: Script updates for flaky tests (#18349)
* flaky fix

* remove only

* NumberSlier & BasicLint fix

* jsform hidden field spec fix

* Theme_MultiSelectWidget_spec.js fix

* Bug 16702 spec fix
2022-11-23 16:02:35 +05:30
Ayangade Adeoluwa
300950b147
fix: Fix response header issues (#17717)
Fix response header issues

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-11-19 19:29:15 +05:30
Favour Ohanekwu
1379180ecd
feat: Split evaluation and linting (#17287)
* Evaluations and Linting now runs on separate web-workers for a much faster and responsive coding experience on Appsmith.
* Removed worker-loader webpack plugin.
2022-11-03 14:53:15 +05:30
akash-codemonk
01805a27f4
fix: show empty canvas CTA's only on the first page while creating an app (#17869) 2022-11-02 14:39:59 +05:30
Aishwarya-U-R
d5d2bf92bb
test: Script updates for flaky tests (#17980)
* JSOnload fix

* mysql fix
2022-11-01 15:31:42 +05:30
Arsalan Yaldram
944ad01686
feat: slider widgets cypress test cases (#17467)
* feat: cypress test cases for the slider widget.

* fix: review changes completed.

* fix: cypress use data-cy selector.

* fix: remove range calculation from range slider stpSize validation.

* fix: added range validation back for stepSize.
2022-10-21 15:55:41 +05:30
Anand Srinivasan
d62e1961d8
fix: Add collapse icon for bottom bar (#16939)
* add containerRef and explandedHeight to enable collapse icon

* change icon

* sizing

* alignment fixes

* consistent height

* remove unwanted padding

* debugger panel height

* remove extra divider line

* open panel on header click

* rename method

* cypress tests init

* jsobject navigate instead of create

* clean up

* remove variable

* undo changes

* final clean up

* logs spec clean up

* debugger locators clean up

* rename locator

* mock db spec fix

* logs spec fix

* clean up records count locator

* Rename dubugger locators and methods

* spec file change

* move methods

* rename debugger helper class

* build fix

* handle selectors

* merge clean up

* fix failing tests

* use single variable to set height

* undo cypress env changes
2022-10-20 17:38:48 +05:30
Rimil Dey
42b913cef8
feat: Add postMessage as a global function (#14925)
## Description

**Revert Context -** 

Reverts appsmithorg/appsmith#14890 (We had to revert the PR as we got some suggestions on improving the feature - now reverting the revert so we can have this feature out with improvements)

**PR Context -** 
This pull request exposes window.postMessage() as a global function in the Appsmith platform.

Post message safely enables cross-origin communication between window objects.
Example use-case - Appsmith page embedded within an iframe which communicates with the container website

Diagram for all the different levels of communication - 
![Untitled-2022-09-12-1205](https://user-images.githubusercontent.com/10229595/189592030-98bc29ac-b94e-4c75-8567-965757cc0d18.png)



**More on post message here** - https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage

**References used for this PR:**

1. Geolocation APIs - https://github.com/appsmithorg/appsmith/pull/9295
2. setInterval and clearInterval support - https://github.com/appsmithorg/appsmith/pull/8158

**Fixes** https://github.com/appsmithorg/appsmith/issues/7241

## Type of change

- New feature (non-breaking change which adds functionality)

## How Has This Been Tested?

Test plan 
- **Manual**: Created an app with different buttons holding different types of data and embedded it in a code sandbox within an iframe. Also removed the target origin which throws an error (App link - https://dev.appsmith.com/app/post-msg-app/page1-624c1af4d8e632741017682e, Codesandbox link - https://codesandbox.io/s/compassionate-tdd-6dnzzd?file=/src/index.js)
- Added Jest tests
- https://github.com/appsmithorg/TestSmith/issues/1892
- https://github.com/appsmithorg/TestSmith/issues/2068
- https://github.com/appsmithorg/TestSmith/issues/2069

- [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

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-10-20 12:39:42 +05:30
arunvjn
28138c18c8
feat: enabled setTimeout/clearTimeout APIs (#17445) 2022-10-17 22:40:17 +05:30
Hetu Nandu
3aff53187c
feat: Maintain Focus and Context Phase 1 (#16317) 2022-10-17 20:46:38 +05:30
Ayangade Adeoluwa
282f1ff5a6
feat: Adds one way switching to Form Controls (#17194)
* Adds one way switching to Form Controls

* Fix failing jest test

* Retrigger oktotest

* JSOnload1 spec 6th case fix

* Jsonloadspec 1 fix

Co-authored-by: Aishwarya-U-R <91450662+Aishwarya-U-R@users.noreply.github.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-10-13 21:28:46 +01:00
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
Aishwarya-U-R
a255486087
test: Script updates for flaky tests to unblock CI (#17469) 2022-10-13 12:54:09 +05:30
Nidhi
74c3dbbc1a
fix: Modified on page load actions calculation using AST (#17074)
* Changes to on page load logic and consumption for update layout

* Slight clean up, tests and stuff

* - Added evaluationVersion logic based on application configuration
- Added configuration for slim and fat container rts availability
- Added backup logic of string comparison for slim containers
- Added tests for both paths

* Changes to on page load logic and consumption for update layout

* Slight clean up, tests and stuff

* Cleaned up comments all over

* Why isn't there even a setting to disable auto re-formats

* update rts logic to use updated shared AST logic

* Make changes to naming conventions

* Some temp stuff to check if update layout API changes will work out

* Added health check endpoint in RTS

* Added types for AST request

* update: type for save page request object

* update: return type for getEditorConfigs func

- Added applicationId to the type.
- Fetching from the redux store -> applications -> currentApplication -> id

* update: url generation func for update page API

- added applicationId as query param for the call

* Fixed test failures

* Fixed merge from release with on page load failure messages

* Fixed tests failing after merge

* Review comments, more tests, and fix for array index ref directly after .data path

* Test fix

* Addressed review comments

* Updated comment

* Fixed rts temporarily, added handling for data as function name, left with tests

* fix: failing rts server

* Tests for all types of actions and references

* Changes to test

* Modified type to set

* Test fixes

* Trying to make a test pass

* Added app id in cypress test update dsl

* Added app id in cypress test update dsl

* Added app id in cypress test update dsl

* Removed dep tree temp file

* Resolving compile issues after merging from release

* updated tests for applicationId

* corrected a typo

* fixed some more tests

* updated test

* Updated test

* DSL load AppId fix

* appId removal

* AgHelper LocalStorageCache()

* AgHelper LocalStorageCache() - commit 2

* AgHelper LocalStorageCache() - commit 3

* AgHelper LocalStorageCache() - commit 4

* AllWidgets_Reset_spec - Dsl fix

* Json_spec fix

* S3_2 spec fix

* fixes

* LocalStorageCache fixes

* fixes

* fixes

* fix

* OnLoadActions spec fix

* Promises spec fix

* S3_2 spec fix

* 16702 spec update

* OnLoadActions spec trial fix

* RTS fix

Co-authored-by: Nidhi Nair <cataclysm@Nidhis-MacBook-Pro.local>
Co-authored-by: Ayangade Adeoluwa <adeoluayangade@yahoo.com>
Co-authored-by: Ayush Pahwa <ayush@appsmith.com>
Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Apple <nandan@thinkify.io>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-10-11 11:02:44 +05:30
Aman Agarwal
ab106455f2
fix: adding mode for graphql syntax with dynamic bindings (#17229)
fix: added mode for dynamic binding with quote for graphql
2022-10-08 03:17:07 +01:00
Aman Agarwal
78c89894f8
fix: updated settings page design (#16990)
fix: updated settings page design
2022-10-06 16:36:29 +05:30
Aishwarya-U-R
7596dfc35a
test: Script updates for flaky tests to unblock CI (#17264) 2022-10-03 15:25:11 +05:30
akash-codemonk
a560051d86
feat: fork templates inside an existing app (#17184) 2022-09-30 19:11:04 +05:30
Arpit Mohan
c036087379
chore: Import template application to a git branch in application (#17032)
Also fixing the comodification array error when we are removing items from a list while iterating over it.
Fixes #17030

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-09-29 14:39:19 +05:30
Souma Ghosh
88fe538a70
feat: Autoassigns column datatype in table widget (#16701)
* feat: Autoassigns column datatype in table widget
- Limited to only number, string and boolean datatypes

* Review changes
Adjust jest tests accordingly

* Adds support for recognising Date type columns
Review changes

* Adds jest test for Date field

* Fix warning

* Adjust cypress tests and add helper method to account for code changes

* Fix failing test
2022-09-29 10:56:08 +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
Rishabh Rathod
9a1fa98416
fix: Autocomplete now works with multiple bindings (#16314)
Fixes #16288
Fixes #16158
Fixes #16188
Fixes #15859
2022-09-19 11:02:06 +05:30
ChandanBalajiBP
2b70914f31
test: mysql datatypes cypress test cases (#16696)
* test: mysql datatypes cypress test cases

* test: cypress added comments with cleaner code

* updates w.r.t review comments

* fix 10th cases failure

* fix for test failing on CI

* fix for test failing on CI another way

* fix: address review comments
2022-09-16 11:51:25 +05:30
Ayangade Adeoluwa
342c5cc673
fix: Fix Api url path issue (#16628)
* Fix Api url path issue

* Modify test cases
2022-09-13 05:02:59 +00:00
Aishwarya-U-R
bdadb827e3
test: Script updates for flaky tests (#16631)
* CreateNewApp spec flaky fix

* fix

* Moved RepoLimit to commented files

* Inline spec failure fix - case 19

* Table FIlter specs V1/V2 split

* Binding/Table_Property_ToggleJs spec - V1/V2 fix

* Spec name update

* Wait increase

* DS - duplicate error capture fix

* revert

* Recaptcha spec fix

* Jsfun exe flaky fix - unskipped case

* jsfunc exec spec fix

* jsfunex spec fix

* Api bugs spec fix

* Api bugs spec fix

* Chartdata point spec flaky fix

* Theme_multiselect brown type fix

* Jsfunc exe spec fix

* Inline spec fix

* Inline spec fix

* Inline spec fix

* Theme multiselect spec fix

* Promises spec fix

* JSFun Exe spec fix

* Api_all verb methods update

* List1 spec 4th case fix

* Jsfun exe skipping 10th case

* jsunf exe 10th case trial fix

* firestore stub error capture

* jsonload failng spec skip

* JSonload spec fix

* json load spec fix

* Git repo moved back
2022-09-12 09:48:44 +05:30
Sumit Kumar
0cbe81dfde
feat: merge GraphQL plugin to release (#16554)
* merge GraphQL plugin to release
2022-09-09 21:29:47 +05:30
Aishwarya-U-R
bf232dbb7e
test: Script updates for flaky tests (#16558) 2022-09-07 23:55:55 +05:30
Aishwarya-U-R
353e007e78
test: Script updates for flaky tests (#16533)
* Autosave trial fix

* json form field flaky fix

* js fun exe spec flaky fix
2022-09-06 08:59:39 +05:30
Aishwarya-U-R
06cd7542f5
test: Script updates for flaky tests (#16455)
* UUID table load time increase

* Autocomplete js api failiure fix

* mysql crud fix

* MySQL, Postgres CRUD updates

* flaky fix

* flaky fix

* Upgrade Appsmith spec - moved

* MySQL CRUD spec split

* fix

* fix

* fix

* fix

* Postgres CRUD spec split

* Postgres CRUD spec split

* fix

* EE names update

* fix

* fix
2022-09-05 15:24:56 +05:30
Aswath K
8b297e4da1
chore: Property pane design changes (#16112) 2022-09-05 10:22:39 +05:30
Ayush Pahwa
7d621de978
feat: console log implementation in appsmith (#16286)
* feat: capture console from across the app (#15676)

* create: console override file

- Adds methods to override the given console functionality to capture the console statements written by the user

* update: evaluate function to extract console op

- Added logs extraction for both sync and async functions
- Adding them to the return object of the evaluations

* update: timestamp field to log addition method

- Added optional argument to function definition for inputting the timestamp of the log
- This is done to maintain timings of the execution of the log

* update: interface for log objects

* update: post function execution logic

- Added logic to push the logs generated by the evaluation to the logs store

* update: added handling for sending nested fns

- While console logging functions or objects that had functions was causing an error
- Added a check for removing functions and replacing them with name of the functions instead

* chore: added types and comments

* fix: updated evaluation tests

* fix: added check for log in returned obj

* update: added the source data in the trigger logs

- Removed on js execute logs from showing up here since they are already handled. If they are not removed, they will show up on the first page load twice

* add: ellipsis function for log title string

- This is to keep big object contained in the first line only

* update: made logs reset function public

* update: resetting logs before new eval

- Logs object has to be cleared before next eval can happen to make sure there are no roll overs from last evals

* chore: added comments

* add: extracting logs after eval of functions

* add: storing logs to redux after eval

* refactor: updated types

* add: func to store logs w/ severity as arg

* refactor: updating func call for user logs

* chore: fixed elipsis logic

* chore: removed unused type

* chore: updated preview text logic

* add: type for transfer object post eval

* update: aded new userLogs obj to dataTreeEvaluator

* update: passing logs from object to saga

* update: parsing received userlogs

* refactor: used predefined fns

* refactor: moved resetlogs to common func

* chore: updated comments

* feat: update redux store and UI for system + user logs (#15936)

* update: updated types for the redux store

- Added category and data fields in the log object

* update: types of log redux store

* update: calls for the console log store function

* update: icon fetch func for log item UI

* update: syncing UI with the new designs (WIP)

* chore: fixed lint error

* update: filters for logs

* update: icon for clearing log filters

* update: filtering function

- Added checks against category and severity

* update: logitem UI

- updated type of the UI object
- added css based ellipsis
- added toggle for console logs
- added array of json views for objects/arrays
- css tweaks

* update: debugger cta

- Removed copy option
- Updated UI

* update: logic for expanding user logs

- Removed debugger CTA
- Fixed position for the expand/collapse icon
- Added joining char for when the log is expanded

* update: assets for new UI

- updated colors
- Added new icon

* hotfix: ternserver code

* add: search across the text of log

* update: icons for the app

* update: click to expand/collapse of logs

* fix: search keyword update on change within JSObjects

* fix: alignment of log items in both states

* update: jest tests for debugger errors and filter

* fix: drop down options color issue

- the icon used was not the standard one
- We have a lot of duplicates of the same icon

* fix: synced with ADS changes on release

* fix: remove dependency from old icon

* add: cypress selectors for automation testing

* fix: replaced static messages with variables

* fix: updated the dependency map for filter

* fix: height of the filter drop down

* fix: chaining logic for search filter

* fix: syncing the padding values to ADS

* fix: help icon visibility issue

* fix: width of filter dropdown

Co-authored-by: Rishabh-Rathod <rishabh.rathod@appsmith.com>

* add: e2e tests for console statements using IIFE

* test: added test for console logs in jsobjects

* fix: functionality of expanding context menu on msg click

* fix: added try catch and handling for numbers

* hotfix: handling unwanted toasts

* fix: alignment and clickable cursor

* fix: alignment of expanded span in console logs

* add: analytics event on new console log created

* fix: added handling for boolean and undefined

* fix: removed log reset from common func

- Whenever we are creating global DTO, the logs were being reset. This caused logs to reset whenever a promise was encountered in the logs.

* fix: combined JS log saving to widget process

* add: new analytics event on filter changed

* update: added handling for empty value

* update: removed comma between multiple logs

* update: synced test changes with release

* update: removed unused wait timings

* Logs spec script update

* update: ts methods in log spec e2e test

* logs spec update

* update: removed body clicks from test script

* Logs spec update

* update: removed ask from google option

* refactor: ui fixes

* fix: text selection of logs

* fix: updated dropdown width management

* update: made the flushlogs function async

* update: added handling for promises

* update: added test with promises fail and pass

* fix: added sync variant to work for sync objects

* refactor: commented out unused tests

* update: exceptions in the name of log entity

* fix: pagination of logs to handle dynamic data stream

* fix: removed unused async function

* fix: moved logs handling to separate saga

* fix: color for context menu text

Co-authored-by: Rishabh-Rathod <rishabh.rathod@appsmith.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-09-04 17:28:05 +05:30
Aswath K
db08b16d4e
feat: Grouping & reorganisation of Property Pane (#15768)
* Removes feature flag from Client code

* Updates Cypress tests
2022-09-03 18:20:39 +05:30
Ankita Kinger
e28e89807c
feat: Refactor invite modal for handling RBAC updates (#16405)
* refactored code for invite modal changes for rbac

* code splitted some more files for refactoring invite modal component

* removed unused imports

* created new variable for handlers

* updated an import

* reverted a change

* refactored a section of code

* fixed a cypress test

* fixed a cypress test

* updated imports

* exported some entities
2022-09-02 22:45:08 +05:30