PromucFlow_constructor/app/client/cypress/locators/commonlocators.json
ashit-rath 32fee08c5c
feat: JSON Form widget (#8472)
* initial layout

* updated parser to support nested array

* array field rendering

* changes

* ts fix

* minor revert FormWidget

* modified schema structure

* select and switch fields

* added checkbox field

* added RadioGroupField

* partial DateField and defaults, typing refactoring

* added label and field type change

* minor ts changes

* changes

* modified widget/utils for nested panelConfig, modified schema to object approach

* array/object label support

* hide field configuration when children not present

* added tooltip

* field visibility option

* disabled state

* upgraded tslib, form initial values

* custom field configuration - add/hide/edit

* field configuration - label change

* return input when field configuration reaches max depth

* minor changes

* form - scroll, fixedfooter, enitity defn and other minior changes

* form title

* unregister on unmount

* fixes

* zero state

* fix field padding

* patched updating form values, removed linting warnings

* configured action buttons

* minor fix

* minor change

* property pane - sort fields in field configuration

* refactor include all properties

* checkbox properties

* date properties

* refactor typings and radio group properties

* switch, multselect, select, array, object properties

* minor changes

* default value

* ts fixes

* checkbox field properties implementation

* date field prop implementation

* switch field

* select field and fix deep nested meta properties

* multiselect implementation

* minor change

* input field implementation

* fix position jump on field type change

* initial accordian

* field state property and auto-complete of JSONFormComputeControl

* merge fixes

* renamed FormBuilder to JSONForm

* source data validation minor change

* custom field default value fix

* Editable keys for custom field

* minor fixes

* replaced useFieldArray with custom logic, added widget icon

* array and object accordian with border/background styling

* minor change

* disabled states for array and objects

* default value minor fix

* form level styles

* modified logic for isDisabled for array and object, added disabledWhenInvalid, exposed isValid to fieldState for text input, removed useDisableChildren

* added isValid for all field types

* fixed reset to default values

* debounce form values update

* minor change

* minor change

* fix crash - source data change multi-select to array, fix crash - change of options

* fix positioning

* detect date type in source data

* fix crash - when object is passed to regex input field

* fixed default sourceData path for fields

* accodion keep children mounted on collapse

* jest test for schemaParser

* widget/helper and useRegisterFieldInvalid test

* tests for property config helper and generatePanelPropertyConfig

* fix input field validation not appearing

* fix date field type detection

* rename data -> formData

* handle null/undefined field value change in sourceData

* added null/undefined as valid values for defaultValue text field

* auto detect email field

* set formData default value on initial load

* switch field inline positioning

* field margin fix for row direction

* select full width

* fiex date field default value - out of range

* fix any field type to array

* array default value logic change

* base cypress test changes

* initial json form render cy test

* key sanitization

* fix fieldState update logic

* required design, object/array background color, accordion changes, fix - add new custom field

* minor change

* cypress tests

* fix date formatted value, field state cypress test

* cypress - field properties test and fixes

* rename test file

* fix accessort change to blank value, cypress tests

* fix array field default value for modified accessor

* minor fix

* added animate loading

* fix empty state, add new custom field

* test data fix

* fix warnings

* fix timePrecision visibility

* button styling

* ported input v2

* fix jest tests

* fix cypress tests

* perf changes

* perf improvement

* added comments

* multiselect changes

* input field perf refactor

* array field, object field refactor performance

* checkbox field refactor

* refectored date, radio, select and switch

* fixes

* test fixes

* fixes

* minor fix

* rename field renderer

* remove tracked fieldRenderer field

* cypress test fixes

* cypress changes

* array default value fixes

* arrayfield passedDefaultValue

* auto enabled JS mode for few properties, reverted swith and date property controls

* cypress changes

* added widget sniping mode and fixed object passedDefaultValue

* multiselect v2

* select v2

* fix jest tests

* test fixes

* field limit

* rename field type dropdown texts

* field type changes fixes

* jest fixes

* loading state submit button

* default source data for new widget

* modify limit message

* multiseelct default value changes and cypress fix

* select default value

* keep default value intact on field type change

* TextTable cypress text fix

* review changes

* fixed footer changes

* collapse styles section by default

* fixed footer changes

* form modes

* custom field key rentention

* fixed footer fix in view mode

* non ascii characters

* fix meta merge in dataTreeWidget

* minor fixes

* rename useRegisterFieldInvalid.ts -> useRegisterFieldValidity.ts

* modified dependency injection into evaluated values

* refactored fixedfooter logic

* minor change

* accessor update

* minor change

* fixes

* QA fixes date field, scroll content

* fix phone number field, removed visiblity option from array item

* fix sourceData autocomplete

* reset logic

* fix multiselect reset

* form values hydration on widget drag

* code review changes

* reverted order of merge dataTreeWidget

* fixes

* added button titles, fixed hydration issue

* default value fixes

* upgraded react hook form, modified array-level/field-level default value logic

* fixed select validation

* added icon entity explorer, modified icon align control

* modify accessor validation for mongo db _id

* update email field regex

* review changes

* explicitly handle empty source data validation
2022-03-24 12:43:25 +05:30

169 lines
9.7 KiB
JSON

{
"editIcon": ".t--widget-propertypane-toggle",
"helpIcon": ".t--widget-help-control",
"editPropCrossButton": ".t--property-pane-close-btn",
"editPropBackButton": ".t--property-pane-back-btn",
"deleteWidgetIcon": ".t--widget-delete-control",
"dropdownSelectButton": ".t--open-dropdown-Select-Action",
"crossbutton": ".t--property-pane-close-btn",
"dropdownAction": ".t--open-dropdown-Select-Action",
"datatypedropdown": ".t--property-control-datatype button",
"Alerttypedropdown": ".t--open-dropdown-Select-type",
"dropdownmenu": ".t--dropdown-option",
"containerInnerText": ".t--draggable-containerwidget span.t--widget-name",
"optionchangetextDropdown": " .t--property-control-onoptionchange .CodeMirror-code",
"optionchangetextDatePicker": " .t--property-control-ondateselected .CodeMirror-code",
"optionchangetextCheckbox": ".t--property-control-oncheckchange .CodeMirror-code",
"optionchangetextSwitch": ".t--property-control-onchange .CodeMirror textarea",
"optionchangetextInput": ".t--property-control-ontextchanged .CodeMirror-code",
"optionchangeRadioselect": ".t--property-control-onselectionchange .CodeMirror textarea",
"optionalignment": ".t--property-control-alignment .bp3-popover-target",
"onMarkerclick": ".t--property-control-onmarkerclick .CodeMirror-code",
"success": "div[type='success'] span",
"mapOptionChange": ".t--property-control-onmarkerclick .CodeMirror-code",
"dropdownbuttonclick": ".bp3-button",
"menuSelection": ".bp3-button > .bp3-button-text",
"scrollView": ".t--property-control-scrollcontents input",
"InputforText": ".t--property-control-text .CodeMirror-code",
"TextInside": ".bp3-ui-text span",
"homeIcon": ".t--appsmith-logo",
"typeWidgetName": ".bp3-editable-text-editing>input",
"requiredCheckbox": ".t--property-control-required input[type='checkbox']",
"visibleCheckbox": ".t--property-control-visible input[type='checkbox']",
"allowSelectAllCheckbox": ".t--property-control-allowselectall input[type='checkbox']",
"disableCheckbox": ".t--property-control-disabled input[type='checkbox']",
"hideToolbarCheckbox": ".t--property-control-hidetoolbar input[type='checkbox'",
"labelTextStyle": ".bp3-ui-text span",
"bodyTextStyle": ".bp3-ui-text span",
"headingTextStyle": ".bp3-ui-text span",
"editWidgetName": ".t--propery-page-title",
"dropDownIcon": ".t--property-control-textsize .bp3-popover-target",
"onDateSelectedField": ".t--property-control-ondateselected",
"TableRow": ".t--draggable-tablewidget .tbody",
"Disablejs": ".t--property-control-disabled",
"spellCheck": ".t--property-control-spellcheck",
"requiredjs": ".t--property-control-required",
"allowScroll": ".t--property-control-allowscroll input",
"tableInner": ".t--draggable-tablewidget span.t--widget-name",
"buttonInner": ".t--draggable-buttonwidget span.t--widget-name",
"inputWidgetInner": ".t--draggable-inputwidgetv2 span.t--widget-name",
"pdfSupport": ".t--property-control-pdfexport input",
"ExcelSupport": ".t--property-control-excelexport input",
"dropDownBtn": ".bp3-popover-target",
"disabledField": " .bp3-disabled",
"disabledBtn": " button[disabled='disabled']",
"rteToolbar": " .tox-toolbar__primary",
"inputField": " .bp3-input",
"csvSupport": ".t--property-control-csvexport input",
"backToEditor": ".t--back-to-editor",
"enableSearchLocCheckbox": ".t--property-control-enablesearchlocation input",
"enablePickLocCheckbox": ".t--property-control-enablepicklocation input",
"enableCreateMarkerCheckbox": ".t--property-control-createnewmarker input",
"widgetNameTag": "span.t--widget-name",
"serverSidePaginationCheckbox": ".t--property-control-serversidepagination input",
"rightArrowBtn": "span[icon='chevron-right']",
"toastMsg": ".Toastify__toast.Toastify__toast--default span",
"callApi": ".t--property-control-onpagechange .t--open-dropdown-Select-Action",
"singleSelectMenuItem": ".bp3-menu-item.single-select div",
"multiSelectMenuItem": "rc-select-item.rc-select-item-option div",
"selectMenuItem": ".bp3-menu li>a>div",
"evaluatedTypeTitle": ".t--CodeEditor-evaluatedValue > p:first-of-type",
"evaluatedType": ".t--CodeEditor-evaluatedValue > div:first-of-type pre",
"evaluatedCurrentValue": "div:last-of-type .t--CodeEditor-evaluatedValue > div:last-of-type pre",
"entityExplorersearch": "#entity-explorer-search",
"entitySearchResult": ".t--entity-name:contains('",
"saveStatusContainer": ".t--save-status-container",
"saveStatusIsSaving": "t--save-status-is-saving",
"saveStatusSuccess": ".t--save-status-success",
"saveStatusError": ".t--save-status-error",
"tableNextPage": ".t--table-widget-next-page",
"tablePrevPage": ".t--table-widget-prev-page",
"toastmsg": ".Toastify__toast-body span",
"copyWidget": ".t--copy-widget",
"deleteWidget": ".t--delete-widget",
"dropTarget": ".t--drop-target",
"toastAction": ".t--toast-action",
"toastBody": ".Toastify__toast-body",
"videoInner": ".t--draggable-videowidget span.t--widget-name",
"audioInner": ".t--draggable-audiowidget span.t--widget-name",
"onPlay": ".t--property-control-onplay .t--open-dropdown-Select-Action",
"chooseAction": ".single-select",
"chooseMsgType": ".t--open-dropdown-Select-type",
"onPause": ".t--property-control-onpause .t--open-dropdown-Select-Action",
"changeZoomlevel": ".t--property-control-maxzoomlevel .bp3-popover-target",
"selectedZoomlevel": ".t--property-control-maxzoomlevel .bp3-popover-target ",
"imgWidget": "div[data-testid='styledImage']",
"editColTitle": ".t--propery-page-title",
"editColText": ".t--propery-page-title span",
"changeColType": ".t--property-control-columntype .bp3-popover-target",
"selectedColType": ".t--property-control-columntype button span",
"collapsesection": ".t--property-pane-section-collapse-general .bp3-icon",
"selectTab": ".t--tab-Tab",
"layoutControls": ".t--layout-control-wrapper button",
"layoutPopover": ".bp3-popover.bp3-minimal.layout-control",
"canvas": ".t--canvas-artboard",
"deflautSelectedRow": ".t--property-control-defaultselectedrow textarea",
"defaultSearchText": ".t--property-control-defaultsearchtext textarea",
"entityName": ".t--entity-name",
"entityItem": ".t--entity-item",
"entityCollapseToggle": ".t--entity-collapse-toggle",
"entityContextMenu": ".t--context-menu",
"entityContextMenuContent": ".t--entity-context-menu",
"filePickerButton": ".t--widget-filepickerwidget",
"filePickerInput": ".uppy-Dashboard-input",
"filePickerUploadButton": ".uppy-StatusBar-actionBtn--upload",
"filePickerOnFilesSelected": ".t--property-control-onfilesselected",
"dataType": ".t--property-control-datatype .bp3-popover-target",
"recaptchaVersion": ".t--property-control-googlerecaptchaversion .bp3-popover-target",
"jsonFormFieldType": ".t--property-control-fieldtype .bp3-popover-target",
"jsonFormAddNewCustomFieldBtn": ".t--property-control-fieldconfiguration .t--add-column-btn",
"evaluateMsg": ".t--evaluatedPopup-error",
"globalSearchModal": ".t--global-search-modal",
"globalSearchInput": ".t--global-search-input",
"globalSearchTrigger": ".t--global-search-modal-trigger",
"globalSearchClearInput": ".t--global-clear-input",
"containerWidget": ".t--widget-containerwidget",
"paginationButton": ".rc-pagination-item",
"switchWidgetActive": ".t--switch-widget-active",
"switchWidgetInActive": ".t--switch-widget-inactive",
"switchWidgetLoading": ".t--switch-widget-loading",
"tablePageSizeChangeAction": ".t--property-control-onpagesizechange .t--open-dropdown-Select-Action",
"listWidgetNameTag": ".bp3-editable-text-content",
"currencyType": ".t--property-control-currency .bp3-popover-target",
"decimalType": ".t--property-control-decimals .bp3-popover-target",
"allowCurrencyChange": ".t--property-control-allowcurrencychange input[type='checkbox']",
"inputCurrencyChangeType": ".t--input-currency-change",
"inputCountryCodeChangeType": ".t--input-country-code-change",
"viewerPage": ".t--app-viewer-page",
"dropDownOptSelected": "//span[@type='p1']",
"generalChevran": ".t--property-pane-section-collapse-general [icon=chevron-right]",
"generalSection": ".t--property-pane-section-general",
"selectedIcon": ".t--property-control-icon .icon-select-container .bp3-button .bp3-button-text",
"isSortable": ".t--property-control-sortable input[type='checkbox']",
"labelSection": ".cm-keyword",
"lintWarning": ".CodeMirror-lint-mark-warning",
"lintErrorMsg": ".CodeMirror-lint-message-error",
"lintWarningMsg": ".CodeMirror-lint-message-warning",
"labelSectionTxt": ".CodeMirror-code .cm-variable",
"lintError": ".CodeMirror-lint-mark-error",
"debugger": ".t--debugger svg",
"errorTab": "[data-cy=t--tab-ERROR]",
"debugErrorMsg": ".t--debugger-message",
"debuggerLabel": "span.debugger-label",
"debuggerContextMenu":".t--debugger-contextual-error-menu",
"cyclicDependencyError": "//div[@class='Toastify']//span[contains(text(),'Cyclic dependency found while evaluating')]",
"openDocumentationfromErrorTab":"//span[@name='book-line']",
"appNameDeployMenu": ".t--app-name-menu-deploy-parent",
"appNameDeployMenuPublish": ".t--app-name-menu-deploy",
"appNameDeployMenuCurrentVersion": ".t--app-name-menu-deploy-current-version",
"appNameDeployMenuConnectToGit": ".t--app-name-menu-deploy-connect-to-git",
"selectInner": ".t--draggable-selectwidget span.t--widget-name, Select1",
"toastifyError": "//div[@class='Toastify']//span]",
"selectwidget": ".t--draggable-selectwidget",
"textWidget": ".t--draggable-textwidget",
"filepickerv2": ".t--draggable-filepickerwidgetv2",
"dashboardItemName": ".uppy-Dashboard-Item-name",
"mapChartShowLabels": ".t--property-control-showlabels input",
"widgetSection": ".t--entity.widgets > .t--entity-item > a.t--entity-collapse-toggle"
}