Commit Graph

11436 Commits

Author SHA1 Message Date
sanjus-robotic-studio
5bdfe7de0e
fix: Add a toolbar option for the line height in Rich Text Editor (#17859) 2022-10-25 17:11:42 +05:30
Anagh Hegde
45baf8cd2f
chore: Add git file system env to server setup guidelines (#17858)
## Description

> Local server set up requires configuring the env variable APPSMITH_GIT_ROOT to be configured. This is PR adds the same info to the docs for the server set-up guidelines.
2022-10-25 11:17:18 +05:30
yatinappsmith
2123110d7f
ci: fix fat-container combined (#17742)
Fixed ui-test.result check
2022-10-25 11:01:26 +05:30
Anagh Hegde
e6d31115ee
fix: After merging the template the deployed version of the App was failing to load (#17753)
* WIP

* Do not update published pages while merging template for the existing App

* Add test case
2022-10-25 10:57:51 +05:30
Rimil Dey
58a2632f75
chore: move render field to component (#17084)
## Description

As part of the action selector refactor, we are making the following changes - 
- moving renderField to its own component called Field
- created FieldConfig to hold all the configurations of these functions fields: This config will slowly be built up to hold all the miscellaneous configurations which is currently scattered throughout different files
- added types for the props
- moved FieldConfig to its own type

Fixes #16934 #16936

## Type of change

- Refactor

## How Has This Been Tested?

- manually
- Jest test cases

## Checklist:

- [x] My code follows the style guidelines of this project
- [x] 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
- [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
2022-10-24 11:04:55 +05:30
Trisha Anand
9f1488a623
chore: Code split and refactor for inviteUser flow (#17807) 2022-10-23 15:30:19 +05:30
Appsmith Bot
506f202926 Update top contributors 2022-10-23 06:59:52 +05:30
Vishnu Gp
31b03e8939
chore: Changes in layout and theme analytics events (#17827) 2022-10-22 21:50:32 +05:30
Arpit Mohan
82bf01fce9
chore: Update READ_PERMISSION_GROUP to PERMISSION_GROUP_MEMBERS (#17826) 2022-10-22 17:40:21 +05:30
Arpit Mohan
86c21b3af9
chore: Fixing flaky behaviour in SeedMongoData (#17812) 2022-10-22 12:47:51 +05:30
Appsmith Bot
33dd5fead4 Update top contributors 2022-10-22 06:59:43 +05:30
Ankita Kinger
3bf84de8d1
fix: Updating left panel CSS on home page (#17813)
* updating left panel height on home page due to addition of admin settings

* fixing the left panel styles on homepage
2022-10-21 23:05:54 +05:30
Pawan Kumar
86c9ac36a9
fix: MultiSelect/TreeSelect widget deselects on clicking again (#17530)
hide backdrop
2022-10-21 20:22:55 +05:30
Ankita Kinger
f9e516cccd
fix: Add max dropdown height (#17805)
added max dropdown height
2022-10-21 19:20:52 +05:30
Ankita Kinger
eec469e729
fix: Updating left panel height on home page due to addition of admin settings (#17788)
updating left panel height on home page due to addition of admin settings
2022-10-21 16:34:12 +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
Souma Ghosh
408d116c44
fix: Incorrect page count when number of records in page is different from page size (#17535) 2022-10-21 13:14:46 +05:30
ramsaptami
ea070517d3
chore: update PR template to include QA details (#17754) 2022-10-21 12:29:55 +05:30
Pawan Kumar
f310e858bf
feat: Add a read only mode to rating widget (#17465)
* add readonly prop + migrate disabled to readonly for rate widget

* add comment

* add check for dynamic value

* add readonly to dynamic property list in migration

* add tooltip in readonly state too

* fix jest tests

* dummy commit to fix git file name issue

* dummy commit to fix git file name issue
2022-10-21 12:25:18 +05:30
Rishabh Rathod
8fe7f9291d
feat: Add validation dependency (#17138)
## Problem

**Why do we need validation dependency?**

- When on change of particular property value if other property needs revalidation then current evaluation architecture do not support such validation run.

https://www.notion.so/appsmith/Validation-Dependency-d7623a5625bd4aa187a3ae2372d3ac07

**Issues to resolve**

Fixes #15303
Fixes #17159
Fixes https://github.com/appsmithorg/appsmith/issues/16170

## Solution

**New Validation Flow**

validate a property after its evaluation and check if there are other properties that need to revalidate on a change of this value. 

- if yes run validation for those properties.

How does validation dependency get created?

- every widget’s property will keep static `dependencies` array in `validation` property like shown below.

```jsx
{
	validation: {
    type: ValidationTypes.FUNCTION,
    params: {
      fn: defaultOptionValueValidation,
      expected: {
        type: 'value1 or { "label": "label1", "value": "value1" }',
        example: `value1 | { "label": "label1", "value": "value1" }`,
        autocompleteDataType: AutocompleteDataType.STRING,
      },
      dependentPaths: ["serverSideFiltering", "options"],
    },
    dependencies: ["serverSideFiltering", "options"],
  }
}
```

This `dependentPaths` array will be used to form validationDependencyMap.
 
#### Changes

- The code editor component wasn't re-rendering for a few cases. Due to this updates were not shown until the component state was changed.

- In CreateFirstTree, After evaluateTree we run `validateTree`. In `validateTree`, we validate all the properties in `validationPaths`. Here, if the errors were resolved on revalidation, it didn't reset the validation errors stored in data tree before. Now, this PR adds the reset logic. 
- Created `validationDependencyMap` to re-validate properties on change of the property their validation depends upon. 
- After each property evaluates in `updateDataTree`, we check if re-validation is needed, if yes then we re-validate dependent properties.  


## Type of change

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)

## How Has This Been Tested?

- jest test

**Test Plan**
https://github.com/appsmithorg/TestSmith/issues/2078

## Checklist:

- [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
- [x] 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
2022-10-21 10:50:57 +05:30
f0c1s
9db612cf92
fix: upgrade page for audit logs with correct data (#17697)
## Description

This PR fixes:
- content that was repeated
- has new images
- removes comments
- brings text to messages file

## Compare

| OLD | NEW |
| - | - |
| ![security-and-compliance](https://user-images.githubusercontent.com/1573771/196636819-325d2a42-e992-43a3-91e6-9a1580ddd003.svg) | ![security-and-compliance](https://user-images.githubusercontent.com/1573771/196636392-f9778aef-4f8b-41a5-8408-4e0f636a1437.svg) |
| ![debugging](https://user-images.githubusercontent.com/1573771/196636997-b19c1886-7d7c-460f-a0ea-69ae0030bbe8.svg) | ![debugging](https://user-images.githubusercontent.com/1573771/196637039-389ceb6d-f408-402d-8c0e-3d431fd0dda6.svg) |
| ![incident-management](https://user-images.githubusercontent.com/1573771/196637122-743c03d3-7bd3-4f9b-8a3c-eb0e74735cde.svg) | ![incident-management](https://user-images.githubusercontent.com/1573771/196637182-281a318b-a609-4a74-b5d9-6dabc5d08bfd.svg) |
2022-10-21 10:42:59 +05:30
Arsalan Yaldram
3182dd4116
fix: checkbox & switch widget label alignment. (#17516)
* fix: checkbox label right alignment issue.

* fix: label position and alignment for switch and checkbox widgets.

* fix: test cases for switch and checkbox label alignment.
2022-10-21 09:51:00 +05:30
Ankita Kinger
663aa4b427
refactor: Update styles of admin settings page (#17758)
updating styles of admin settings page
2022-10-20 22:19:30 +05:30
Anagh Hegde
23e6cf3bbf
chore: NPE for action execution tests (#17778) 2022-10-20 19:46:05 +05:30
Aswath K
436205f6e9
fix: Converted Dropdowns to Button group & added missing tooltips (#17454)
* Makes the IconTabControl to have fullWidth property

* Changes dropdown to Button Group & adds missing tooltips
2022-10-20 19:36:32 +05:30
Hetu Nandu
ff15074f82
fix: Response Pane height context restore issue in some cases (#17750) 2022-10-20 18:23:47 +05:30
arunvjn
ddff993722
chore: List widget security fix (#17666)
* fix: ListWidget triggerPaths
* Replace single quote with JSON.stringify to parse trigger fields to avoid code execution via user input.

Co-authored-by: Rishabh-Rathod <rishabh.rathod@appsmith.com>
2022-10-20 17:50:56 +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
Anagh Hegde
bd95ae4ef0
chore: Add action execution params to analytics (#17562) 2022-10-20 13:37: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
Aishwarya-U-R
03fbcdd21c
test: Script updates for flaky tests (#17603)
* Skipping Bug16702 spec

* Bug 16702 fix

* timeout spec index update

* Bug 16702 spec fix

* Bug16702 fix

* BUg16702 spec fix

* Bug 16702 revert

* fix template spec

Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
2022-10-20 11:56:52 +05:30
Sangeeth Sivan
62fb99929e
feat: code split permission helpers and added null check for some selectors (#17718) 2022-10-20 11:33:33 +05:30
Appsmith Bot
8b419a177c Update top contributors 2022-10-20 07:00:11 +05:30
Arpit Mohan
4e71432d74
chore: Adding base repository function to add user permissions to generic domain object (#17733)
## Description

Adding base function to set the user permissions for a user in any domain object. 

As part of this, we also add default permission group to the `SeedMongoData`. Without this fix, the JUnit tests go into an infinite loop. Also fixing the `ExampleWorkspaceClonerTest` file.

## Type of change

- Bug fix (non-breaking change which fixes an issue)

## How Has This Been Tested?

- JUnit

## 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
2022-10-20 03:00:30 +05:30
Arpit Mohan
b2cc280009 chore: Fixing prettier formatting for AnalyticsUtil.tsx 2022-10-19 23:08:25 +05:30
Shrikant Sharat Kandula
39dd761cb0
Change Segment CDN to our proxy (#17714) 2022-10-19 20:29:35 +05:30
Parthvi
0ae012a90e
test: Add cypress tests for template phase 2 (#17036)
Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
2022-10-19 19:43:51 +05:30
Nikhil Nandagopal
aedde34ab2 Updated Label Config 2022-10-19 16:25:51 +05:30
Ayush Pahwa
0248f8e4a9
fix: replace time based action to event based (#17586)
* fix: replace time based action to event based

- The delete datasource button was getting reset to it's original state after a static time of 2200ms
- Replaced this to reset on completion of deletion instead

* fix: removed unused functions

* fix: updated the condition to show confirm delete icon
2022-10-19 16:04:12 +05:30
sanjus-robotic-studio
3a04e1abb1
fix: JS option missing for Label Font Style in Input widget (#17631) 2022-10-19 15:38:48 +05:30
Tanvi Bhakta
e0c8b5d22d
chore: Correct the toast font on windows (#17671) 2022-10-19 15:37:25 +05:30
Vishnu Gp
b470cb29c8
chore: Added workspace details to user invite analytic event (#17644)
## Description

This PR adds the workspace details to user invite analytics event

## Type of change

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

## How Has This Been Tested?

- Manually on local

## Checklist:

- [x] My code follows the style guidelines of this project
- [x] 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
- [x] New and existing unit tests pass locally with my changes
2022-10-19 15:32:41 +05:30
Shrikant Sharat Kandula
8bc97b086e
chore: Add recommended indexes (#17704)
Signed-off-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2022-10-19 14:20:30 +05:30
sneha122
2139382928
fix: table does not show data issue fixed (#17459) 2022-10-19 11:30:04 +05:30
Keyur Paralkar
3a96547815
fix: remove file references on click of cancel button (#17664) 2022-10-19 11:09:01 +05:30
Shrikant Sharat Kandula
973997c606
Fix typo in cloud-hosting check and NPE from Segment (#17692)
Signed-off-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2022-10-19 11:08:36 +05:30
Appsmith Bot
7995ca909d Update top contributors 2022-10-19 07:00:00 +05:30
Vishnu Gp
7a6d2ad314
chore: Corrected analytics event for instance setting events (#17622) 2022-10-19 01:11:05 +05:30
Nidhi
dcaa7af450
chore: Added feature flag for datasource environments (#17657)
chore: Added Feature flag for datasource environments
2022-10-18 15:51:31 +05:30
ChandanBalajiBP
e5cdfbe445
feat: AST based entity refactor (#17434)
* task: AST based entity refactor

* implemented refactor logic

* jest cases with string manipulation using AST logic

* comments and indentation

* added evalVersion to request
2022-10-18 12:07:06 +05:30