diff --git a/app/client/.eslintrc.js b/app/client/.eslintrc.js
index 386c8ee8f04..aa0dd5f9eca 100644
--- a/app/client/.eslintrc.js
+++ b/app/client/.eslintrc.js
@@ -1,18 +1,18 @@
module.exports = {
- parser: '@typescript-eslint/parser',
+ parser: "@typescript-eslint/parser",
plugins: ["react", "@typescript-eslint", "prettier", "react-hooks"],
extends: [
"plugin:react/recommended", // Uses the recommended rules from @eslint-plugin-react
"plugin:@typescript-eslint/recommended",
"prettier/@typescript-eslint",
- "plugin:prettier/recommended"
+ "plugin:prettier/recommended",
],
parserOptions: {
ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features
sourceType: "module", // Allows for the use of imports
ecmaFeatures: {
- jsx: true // Allows for the parsing of JSX
- }
+ jsx: true, // Allows for the parsing of JSX
+ },
},
rules: {
"@typescript-eslint/explicit-function-return-type": 0,
@@ -20,11 +20,12 @@ module.exports = {
"react-hooks/rules-of-hooks": "error",
"@typescript-eslint/no-use-before-define": 0,
"@typescript-eslint/no-var-requires": 0,
+ "import/no-webpack-loader-syntax": 0
},
settings: {
react: {
pragma: "React",
- version: "detect" // Tells eslint-plugin-react to automatically detect the version of React to use
- }
- }
+ version: "detect", // Tells eslint-plugin-react to automatically detect the version of React to use
+ },
+ },
};
diff --git a/app/client/build.sh b/app/client/build.sh
index f2e36f7871f..253ec39cbe4 100755
--- a/app/client/build.sh
+++ b/app/client/build.sh
@@ -2,7 +2,7 @@
GIT_SHA=$(eval git rev-parse HEAD)
echo $GIT_SHA
-REACT_APP_SENTRY_RELEASE=$GIT_SHA craco --max-old-space-size=4096 build --config craco.build.config.js
+REACT_APP_SENTRY_RELEASE=$GIT_SHA EXTEND_ESLINT=true craco --max-old-space-size=4096 build --config craco.build.config.js
rm ./build/static/js/*.js.map
-echo "build finished"
\ No newline at end of file
+echo "build finished"
diff --git a/app/client/cypress.json b/app/client/cypress.json
index 0cee6e22848..37f524063b7 100644
--- a/app/client/cypress.json
+++ b/app/client/cypress.json
@@ -12,5 +12,9 @@
"json": false
},
"viewportHeight": 900,
- "viewportWidth": 1400
-}
\ No newline at end of file
+ "viewportWidth": 1400,
+ "retries": {
+ "runMode": 2,
+ "openMode": 0
+ }
+}
diff --git a/app/client/cypress/fixtures/SimpleBinding.json b/app/client/cypress/fixtures/SimpleBinding.json
new file mode 100644
index 00000000000..b9dad941ce1
--- /dev/null
+++ b/app/client/cypress/fixtures/SimpleBinding.json
@@ -0,0 +1,62 @@
+{
+ "dsl": {
+ "widgetName": "MainContainer",
+ "backgroundColor": "none",
+ "rightColumn": 1224,
+ "snapColumns": 16,
+ "detachFromLayout": true,
+ "widgetId": "0",
+ "topRow": 0,
+ "bottomRow": 1280,
+ "containerStyle": "none",
+ "snapRows": 33,
+ "parentRowSpace": 1,
+ "type": "CANVAS_WIDGET",
+ "canExtend": true,
+ "dynamicBindings": {},
+ "version": 6,
+ "minHeight": 1292,
+ "parentColumnSpace": 1,
+ "leftColumn": 0,
+ "children": [
+ {
+ "isVisible": true,
+ "text": "Label",
+ "textStyle": "LABEL",
+ "textAlign": "LEFT",
+ "widgetName": "Text1",
+ "type": "TEXT_WIDGET",
+ "isLoading": false,
+ "parentColumnSpace": 74,
+ "parentRowSpace": 40,
+ "leftColumn": 3,
+ "rightColumn": 7,
+ "topRow": 4,
+ "bottomRow": 5,
+ "parentId": "0",
+ "widgetId": "pcznwg0g8k"
+ },
+ {
+ "isVisible": true,
+ "text": "{{Text1.text}}",
+ "textStyle": "LABEL",
+ "textAlign": "LEFT",
+ "widgetName": "Text2",
+ "type": "TEXT_WIDGET",
+ "isLoading": false,
+ "parentColumnSpace": 74,
+ "parentRowSpace": 40,
+ "leftColumn": 3,
+ "rightColumn": 7,
+ "topRow": 6,
+ "bottomRow": 7,
+ "parentId": "0",
+ "widgetId": "tgnz7xg7a3",
+ "dynamicBindings": {
+ "text": true
+ }
+ }
+ ]
+ },
+ "layoutOnLoadActions": []
+}
diff --git a/app/client/cypress/fixtures/formWidgetdsl.json b/app/client/cypress/fixtures/formWidgetdsl.json
index a06bc610cad..c0a833484fc 100644
--- a/app/client/cypress/fixtures/formWidgetdsl.json
+++ b/app/client/cypress/fixtures/formWidgetdsl.json
@@ -81,59 +81,6 @@
"widgetId": "xlrmeiioaa"
}
],
- "blueprint": {
- "view": [
- {
- "type": "TEXT_WIDGET",
- "size": {
- "rows": 1,
- "cols": 12
- },
- "position": {
- "top": 0,
- "left": 0
- },
- "props": {
- "text": "Form",
- "textStyle": "HEADING"
- }
- },
- {
- "type": "FORM_BUTTON_WIDGET",
- "size": {
- "rows": 1,
- "cols": 4
- },
- "position": {
- "top": 11,
- "left": 12
- },
- "props": {
- "text": "Submit",
- "buttonStyle": "PRIMARY_BUTTON",
- "disabledWhenInvalid": true,
- "resetFormOnClick": true
- }
- },
- {
- "type": "FORM_BUTTON_WIDGET",
- "size": {
- "rows": 1,
- "cols": 4
- },
- "position": {
- "top": 11,
- "left": 8
- },
- "props": {
- "text": "Reset",
- "buttonStyle": "SECONDARY_BUTTON",
- "disabledWhenInvalid": false,
- "resetFormOnClick": true
- }
- }
- ]
- },
"minHeight": 520,
"type": "CANVAS_WIDGET",
"isLoading": false,
@@ -147,76 +94,6 @@
"widgetId": "sidaue1kdu"
}
],
- "blueprint": {
- "view": [
- {
- "type": "CANVAS_WIDGET",
- "position": {
- "top": 0,
- "left": 0
- },
- "props": {
- "containerStyle": "none",
- "canExtend": false,
- "detachFromLayout": true,
- "children": [],
- "blueprint": {
- "view": [
- {
- "type": "TEXT_WIDGET",
- "size": {
- "rows": 1,
- "cols": 12
- },
- "position": {
- "top": 0,
- "left": 0
- },
- "props": {
- "text": "Form",
- "textStyle": "HEADING"
- }
- },
- {
- "type": "FORM_BUTTON_WIDGET",
- "size": {
- "rows": 1,
- "cols": 4
- },
- "position": {
- "top": 11,
- "left": 12
- },
- "props": {
- "text": "Submit",
- "buttonStyle": "PRIMARY_BUTTON",
- "disabledWhenInvalid": true,
- "resetFormOnClick": true
- }
- },
- {
- "type": "FORM_BUTTON_WIDGET",
- "size": {
- "rows": 1,
- "cols": 4
- },
- "position": {
- "top": 11,
- "left": 8
- },
- "props": {
- "text": "Reset",
- "buttonStyle": "SECONDARY_BUTTON",
- "disabledWhenInvalid": false,
- "resetFormOnClick": true
- }
- }
- ]
- }
- }
- }
- ]
- },
"type": "FORM_WIDGET",
"isLoading": false,
"parentColumnSpace": 74,
@@ -230,4 +107,4 @@
}
]
}
-}
\ No newline at end of file
+}
diff --git a/app/client/cypress/integration/Smoke_TestSuite/Binding/Entity_delete_spec.js b/app/client/cypress/integration/Smoke_TestSuite/Binding/Entity_delete_spec.js
new file mode 100644
index 00000000000..2d14e84a432
--- /dev/null
+++ b/app/client/cypress/integration/Smoke_TestSuite/Binding/Entity_delete_spec.js
@@ -0,0 +1,19 @@
+const dsl = require("../../../fixtures/SimpleBinding.json");
+const widgetsPage = require("../../../locators/Widgets.json");
+
+describe("Binding the multiple widgets and validating default data", function() {
+ before(() => {
+ cy.addDsl(dsl);
+ });
+
+ it("Checks if delete will remove bindings", function() {
+ cy.get(widgetsPage.textWidget)
+ .first()
+ .click({ force: true });
+ cy.get("body").type("{del}", { force: true });
+
+ cy.get(widgetsPage.textWidget)
+ .first()
+ .should("not.have.text", "Label");
+ });
+});
diff --git a/app/client/cypress/integration/Smoke_TestSuite/Binding/InputWidgets_NavigateTo_validation_spec.js b/app/client/cypress/integration/Smoke_TestSuite/Binding/InputWidgets_NavigateTo_validation_spec.js
index a8d4a158308..6298c8b0d7a 100644
--- a/app/client/cypress/integration/Smoke_TestSuite/Binding/InputWidgets_NavigateTo_validation_spec.js
+++ b/app/client/cypress/integration/Smoke_TestSuite/Binding/InputWidgets_NavigateTo_validation_spec.js
@@ -49,6 +49,7 @@ describe("Binding the multiple Widgets and validating NavigateTo Page", function
cy.get(publish.inputGrp)
.first()
.type("123");
+
cy.get(widgetsPage.chartWidget).should("be.visible");
});
});
diff --git a/app/client/cypress/integration/Smoke_TestSuite/FormWidgets/FormReset_spec.js b/app/client/cypress/integration/Smoke_TestSuite/FormWidgets/FormReset_spec.js
index 7e3290ce815..631af0d6330 100644
--- a/app/client/cypress/integration/Smoke_TestSuite/FormWidgets/FormReset_spec.js
+++ b/app/client/cypress/integration/Smoke_TestSuite/FormWidgets/FormReset_spec.js
@@ -20,6 +20,8 @@ describe("Form reset functionality", function() {
.contains("Reset")
.click();
+ cy.wait(500);
+
cy.get(".tr")
.eq(2)
.should("not.have.class", "selected-row");
diff --git a/app/client/cypress/locators/ViewWidgets.json b/app/client/cypress/locators/ViewWidgets.json
index 2c83bf74648..b9606194a0d 100644
--- a/app/client/cypress/locators/ViewWidgets.json
+++ b/app/client/cypress/locators/ViewWidgets.json
@@ -14,7 +14,7 @@
"searchloc": "input[placeholder='Enter location to search']",
"imagecontainer": ".t--draggable-imagewidget span.t--widget-name",
"imageinner": ".t--draggable-imagewidget img",
- "chartInnerText": ".t--draggable-chartwidget text",
+ "chartInnerText": ".t--property-control-title",
"inputChartValue": ".t--property-control-chartdata .CodeMirror textarea",
"chartButton": ".t--property-control-chartdata button",
"rectangleChart": ".t--draggable-chartwidget g rect",
diff --git a/app/client/cypress/support/commands.js b/app/client/cypress/support/commands.js
index 82c3cab0e0e..a747790c176 100644
--- a/app/client/cypress/support/commands.js
+++ b/app/client/cypress/support/commands.js
@@ -882,8 +882,8 @@ Cypress.Commands.add(
Cypress.Commands.add("widgetText", (text, inputcss, innercss) => {
cy.get(commonlocators.editWidgetName)
- .dblclick({ force: true })
- .type(text, { force: true })
+ .click({ force: true })
+ .type(text)
.type("{enter}");
cy.get(inputcss)
.first()
@@ -1174,23 +1174,7 @@ Cypress.Commands.add("getAlert", alertcss => {
.contains("Success")
.click({ force: true });
});
-Cypress.Commands.add("widgetText", (text, inputcss, innercss) => {
- cy.get(commonlocators.editWidgetName)
- .dblclick({ force: true })
- .type(text)
- .type("{enter}");
- cy.get(inputcss)
- .first()
- .trigger("mouseover", { force: true });
- cy.get(innercss).should("have.text", text);
-});
-Cypress.Commands.add("radioInput", (index, text) => {
- cy.get(widgetsPage.RadioInput)
- .eq(index)
- .click()
- .clear()
- .type(text);
-});
+
Cypress.Commands.add("tabVerify", (index, text) => {
cy.get(".t--property-control-tabs input")
.eq(index)
@@ -1213,26 +1197,6 @@ Cypress.Commands.add("togglebarDisable", value => {
.uncheck({ force: true })
.should("not.checked");
});
-Cypress.Commands.add("radiovalue", (value, value2) => {
- cy.get(value)
- .click()
- .clear()
- .type(value2);
-});
-Cypress.Commands.add("optionValue", (value, value2) => {
- cy.get(value)
- .click()
- .clear()
- .type(value2);
-});
-Cypress.Commands.add("dropdownDynamic", text => {
- cy.wait(2000);
- cy.get("ul[class='bp3-menu']")
- .first()
- .contains(text)
- .click({ force: true })
- .should("have.text", text);
-});
Cypress.Commands.add("getAlert", alertcss => {
cy.get(commonlocators.dropdownSelectButton).click({ force: true });
@@ -1251,16 +1215,7 @@ Cypress.Commands.add("getAlert", alertcss => {
.contains("Success")
.click({ force: true });
});
-Cypress.Commands.add("widgetText", (text, inputcss, innercss) => {
- cy.get(commonlocators.editWidgetName)
- .dblclick({ force: true })
- .type(text)
- .type("{enter}");
- cy.get(inputcss)
- .first()
- .trigger("mouseover", { force: true });
- cy.get(innercss).should("have.text", text);
-});
+
Cypress.Commands.add("radioInput", (index, text) => {
cy.get(widgetsPage.RadioInput)
.eq(index)
@@ -1648,8 +1603,6 @@ Cypress.Commands.add("startServerAndRoutes", () => {
cy.route("DELETE", "/api/v1/applications/*").as("deleteApp");
cy.route("DELETE", "/api/v1/actions/*").as("deleteAction");
cy.route("DELETE", "/api/v1/pages/*").as("deletePage");
-
- cy.route("GET", "/api/v1/plugins/*/form").as("getPluginForm");
cy.route("POST", "/api/v1/datasources").as("createDatasource");
cy.route("POST", "/api/v1/datasources/test").as("testDatasource");
cy.route("PUT", "/api/v1/datasources/*").as("saveDatasource");
diff --git a/app/client/package.json b/app/client/package.json
index 186a163c43c..ae1cb29ab76 100644
--- a/app/client/package.json
+++ b/app/client/package.json
@@ -117,14 +117,14 @@
"typescript": "^3.9.2",
"unescape-js": "^1.1.4",
"url-search-params-polyfill": "^8.0.0",
- "workerize-loader": "^1.2.0"
+ "worker-loader": "^3.0.2"
},
"scripts": {
"analyze": "source-map-explorer 'build/static/js/*.js'",
- "start": "REACT_APP_BASE_URL=https://release-api.appsmith.com REACT_APP_ENVIRONMENT=DEVELOPMENT HOST=dev.appsmith.com craco start",
+ "start": "EXTEND_ESLINT=true REACT_APP_ENVIRONMENT=DEVELOPMENT HOST=dev.appsmith.com craco start",
"build": "./build.sh",
"build-local": "craco --max-old-space-size=4096 build --config craco.build.config.js",
- "build-staging": " REACT_APP_ENVIRONMENT=STAGING craco --max-old-space-size=4096 build --config craco.build.config.js",
+ "build-staging": "REACT_APP_ENVIRONMENT=STAGING craco --max-old-space-size=4096 build --config craco.build.config.js",
"test": "CYPRESS_BASE_URL=https://dev.appsmith.com cypress/test.sh",
"test:ci": "CYPRESS_BASE_URL=https://dev.appsmith.com cypress/test.sh --env=ci",
"eject": "react-scripts eject",
@@ -209,4 +209,4 @@
"pre-commit": "lint-staged"
}
}
-}
\ No newline at end of file
+}
diff --git a/app/client/public/index.html b/app/client/public/index.html
index b7befa3bd50..5178386def4 100755
--- a/app/client/public/index.html
+++ b/app/client/public/index.html
@@ -140,7 +140,6 @@
};
-