From 582bdaf673b7da36f24c47b62efd4ba214668651 Mon Sep 17 00:00:00 2001 From: Ilank <63646693+ilan7empest@users.noreply.github.com> Date: Thu, 16 Jun 2022 16:53:53 +0300 Subject: [PATCH] add isOpen prop in FormSelect (#19) --- package.json | 200 ++++++++++---------- src/lib/components/FormSelect/FormSelect.js | 1 + src/lib/components/Wizard/Wizard.js | 6 +- 3 files changed, 104 insertions(+), 103 deletions(-) diff --git a/package.json b/package.json index a8b8f599..ee6485f6 100644 --- a/package.json +++ b/package.json @@ -1,103 +1,103 @@ { - "name": "iguazio.dashboard-react-controls", - "version": "0.0.8", - "description": "Collection of resources (such as CSS styles, fonts and images) and ReactJS 17.x components to share among different Iguazio React repos.", - "main": "dist/index.js", - "module": "dist/index.js", - "files": [ - "dist", - "README.md" + "name": "iguazio.dashboard-react-controls", + "version": "0.0.8", + "description": "Collection of resources (such as CSS styles, fonts and images) and ReactJS 17.x components to share among different Iguazio React repos.", + "main": "dist/index.js", + "module": "dist/index.js", + "files": [ + "dist", + "README.md" + ], + "repository": { + "type": "git", + "url": "git@github.com:iguazio/dashboard-react-controls.git" + }, + "keywords": [ + "Iguazio", + "iguazio", + "MLRun", + "mlrun" + ], + "peerDependencies": { + "classnames": "*", + "lodash": "*", + "prop-types": "*", + "react": "*", + "react-dom": "*", + "react-modal-promise": "*", + "react-transition-group": "*", + "final-form": "*", + "react-final-form": "*" + }, + "devDependencies": { + "@babel/cli": "^7.17.6", + "@babel/core": "^7.17.9", + "@babel/eslint-parser": "^7.17.0", + "@babel/plugin-transform-react-jsx": "^7.17.3", + "@babel/preset-env": "^7.16.11", + "@babel/preset-react": "^7.16.7", + "@storybook/addon-actions": "^6.4.22", + "@storybook/addon-essentials": "^6.4.22", + "@storybook/addon-interactions": "^6.4.22", + "@storybook/addon-links": "^6.4.22", + "@storybook/builder-webpack5": "^6.4.22", + "@storybook/manager-webpack5": "^6.4.22", + "@storybook/preset-create-react-app": "^4.1.0", + "@storybook/react": "^6.4.22", + "@storybook/testing-library": "0.0.9", + "@testing-library/jest-dom": "^5.16.4", + "@testing-library/react": "^12.1.5", + "@testing-library/user-event": "^13.5.0", + "babel-loader": "^8.2.4", + "babel-plugin-inline-react-svg": "^2.0.1", + "classnames": "^2.3.1", + "cross-env": "^7.0.3", + "eslint": "^8.8.0", + "eslint-config-prettier": "^8.3.0", + "eslint-config-react-app": "^7.0.0", + "eslint-plugin-prettier": "^4.0.0", + "eslint-plugin-storybook": "^0.5.10", + "eslint-webpack-plugin": "^3.1.1", + "lodash": "^4.17.21", + "node": "14.19.0", + "prettier": "^2.5.1", + "prop-types": "^15.8.1", + "react": "^17.0.2", + "react-dom": "^17.0.2", + "final-form": "^4.20.7", + "react-final-form": "^6.5.9", + "react-modal-promise": "^1.0.2", + "react-scripts": "5.0.0", + "react-transition-group": "^4.4.2", + "sass": "^1.50.0", + "web-vitals": "^2.1.4", + "webpack": "^5.72.0" + }, + "scripts": { + "start": "react-scripts start", + "build": "react-scripts build", + "test": "react-scripts test", + "eject": "react-scripts eject", + "build-storybook": "build-storybook", + "storybook": "start-storybook -p 6006", + "compile": "rm -rf dist/* && babel src/lib --out-dir dist --copy-files --no-copy-ignored --ignore src/**/*.stories.js" + }, + "eslintConfig": { + "extends": [ + "react-app", + "react-app/jest" + ] + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" ], - "repository": { - "type": "git", - "url": "git@github.com:iguazio/dashboard-react-controls.git" - }, - "keywords": [ - "Iguazio", - "iguazio", - "MLRun", - "mlrun" - ], - "peerDependencies": { - "classnames": "*", - "lodash": "*", - "prop-types": "*", - "react": "*", - "react-dom": "*", - "react-modal-promise": "*", - "react-transition-group": "*", - "final-form": "*", - "react-final-form": "*" - }, - "devDependencies": { - "@babel/cli": "^7.17.6", - "@babel/core": "^7.17.9", - "@babel/eslint-parser": "^7.17.0", - "@babel/plugin-transform-react-jsx": "^7.17.3", - "@babel/preset-env": "^7.16.11", - "@babel/preset-react": "^7.16.7", - "@storybook/addon-actions": "^6.4.22", - "@storybook/addon-essentials": "^6.4.22", - "@storybook/addon-interactions": "^6.4.22", - "@storybook/addon-links": "^6.4.22", - "@storybook/builder-webpack5": "^6.4.22", - "@storybook/manager-webpack5": "^6.4.22", - "@storybook/preset-create-react-app": "^4.1.0", - "@storybook/react": "^6.4.22", - "@storybook/testing-library": "0.0.9", - "@testing-library/jest-dom": "^5.16.4", - "@testing-library/react": "^12.1.5", - "@testing-library/user-event": "^13.5.0", - "babel-loader": "^8.2.4", - "babel-plugin-inline-react-svg": "^2.0.1", - "classnames": "^2.3.1", - "cross-env": "^7.0.3", - "eslint": "^8.8.0", - "eslint-config-prettier": "^8.3.0", - "eslint-config-react-app": "^7.0.0", - "eslint-plugin-prettier": "^4.0.0", - "eslint-plugin-storybook": "^0.5.10", - "eslint-webpack-plugin": "^3.1.1", - "lodash": "^4.17.21", - "node": "14.18.1", - "prettier": "^2.5.1", - "prop-types": "^15.8.1", - "react": "^17.0.2", - "react-dom": "^17.0.2", - "final-form": "^4.20.7", - "react-final-form": "^6.5.9", - "react-modal-promise": "^1.0.2", - "react-scripts": "5.0.0", - "react-transition-group": "^4.4.2", - "sass": "^1.50.0", - "web-vitals": "^2.1.4", - "webpack": "^5.72.0" - }, - "scripts": { - "start": "react-scripts start", - "build": "react-scripts build", - "test": "react-scripts test", - "eject": "react-scripts eject", - "build-storybook": "build-storybook", - "storybook": "start-storybook -p 6006", - "compile": "rm -rf dist/* && babel src/lib --out-dir dist --copy-files --no-copy-ignored --ignore src/**/*.stories.js" - }, - "eslintConfig": { - "extends": [ - "react-app", - "react-app/jest" - ] - }, - "browserslist": { - "production": [ - ">0.2%", - "not dead", - "not op_mini all" - ], - "development": [ - "last 1 chrome version", - "last 1 firefox version", - "last 1 safari version" - ] - } + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + } } diff --git a/src/lib/components/FormSelect/FormSelect.js b/src/lib/components/FormSelect/FormSelect.js index 7f7b6b50..5786e1e1 100644 --- a/src/lib/components/FormSelect/FormSelect.js +++ b/src/lib/components/FormSelect/FormSelect.js @@ -221,6 +221,7 @@ const FormSelect = ({ variant: selectedItemAction.confirm.btnConfirmType }} header={selectedItemAction.confirm.title} + isOpen={isConfirmDialogOpen} message={selectedItemAction.confirm.message} /> )} diff --git a/src/lib/components/Wizard/Wizard.js b/src/lib/components/Wizard/Wizard.js index 7bc1ac70..f23349ff 100644 --- a/src/lib/components/Wizard/Wizard.js +++ b/src/lib/components/Wizard/Wizard.js @@ -146,9 +146,9 @@ Wizard.propsTypes = { className: PropTypes.string, confirmClose: PropTypes.bool, FormState: PropTypes.object.isRequired, - isOpen: PropTypes.bool.isRequired, - onResolve: PropTypes.func.isRequired, - onSubmit: PropTypes.func.isRequired, + isWizardOpen: PropTypes.bool.isRequired, + onWizardResolve: PropTypes.func.isRequired, + onWizardSubmit: PropTypes.func.isRequired, size: MODAL_SIZES, title: PropTypes.string.isRequired, stepsConfig: WIZARD_STEPS_CONFIG,