formio / angular

JSON powered forms for Angular
https://formio.github.io/angular-demo
MIT License
639 stars 469 forks source link

how to remove all edit form popup preview panel #775

Closed rengarajan098015 closed 8 months ago

rengarajan098015 commented 3 years ago

Hi,

how to remove all edit form popup preview panel after that buttons align left. https://formio.github.io/angular-demo/#/forms/builder Working based on above sample.

image

<form-builder [form]="form" [options]="optionsdata" (change)="onChange($event)"></form-builder>

`optionsdata: any = { builder: { basic: false, advanced: false, data: false, custombasic: { title: 'Basic', weight: 10, default: true, components: { numeric: { title: 'Numeric', key: 'number', icon: 'hashtag', schema: { FieldTypeID: "1", label: 'Number', type: 'number', key: 'number', input: true } }, text: { title: 'Text', key: 'text', icon: 'terminal', schema: { FieldTypeID: "2", label: 'Label', type: 'textfield', key: 'TextKey', input: true } }, textarea: { title: 'Textarea', key: 'textarea', icon: 'font', schema: { FieldTypeID: "3", label: 'Textarea', type: 'textarea', key: 'textarea', input: true } }, date: { title: 'Date', key: 'date', icon: 'calendar', schema: { FieldTypeID: "5", label: 'Date', type: 'day', key: 'day', input: true } }, time: { title: 'Time', key: 'time', icon: 'clock-o', schema: { FieldTypeID: "6", label: 'Time', type: 'time', key: 'time', input: true } }, // datetime: { // title: 'Date Time', // key: 'datetime', // icon: 'calendar', // schema: { // label: 'Date Time', // type: 'datetime', // key: 'datetime', // input: true // } // } } },

      layout: {
        ignore: true,
        components: {
          table: false
        }
      },
      premium:
      {
        ignore: true
      }
    },
    editForm: {
        textfield: [
          {
            key: 'validation',
            ignore: true
          },
          {
            key: 'api',
            ignore: true
          },
          {
            key: 'data',
            ignore: true
          },
          {
            key: 'logic',
            ignore: true
          },
          {
            key: 'layout',
            ignore: true
          },
          {
            key: 'conditional',
            ignore: true
          },
          {
            key: 'display',
            label: 'Basic',
            components: [
                {
                    key: 'tooltip',
                    ignore: true
                },
                {
                    key: 'placeholder',
                    ignore: true
                },
                {
                    key: 'prefix',
                    ignore: true
                },
                {
                    key: 'suffix',
                    ignore: true
                },
                {
                    key: 'inputMasks',
                    ignore: true
                },
                {
                    key: 'allowMultipleMasks',
                    ignore: true
                },
                {
                    key: 'description',
                    ignore: true
                },
                {
                    key: 'customClass',
                    ignore: true
                },
                {
                    key: 'inputMask',
                    ignore: true
                },
                {
                    key: 'tabindex',
                    ignore: true
                },
                {
                    key: 'type',
                    ignore: true
                },
                {
                    key: 'inputMaskPlaceholderChar',
                    ignore: true
                },
                {
                    key: 'labelPosition',
                    ignore: true
                },
                {
                    key: 'autocomplete',
                    ignore: true
                },
                {
                    key: 'widget.type',
                    ignore: true
                },
                {
                    key: 'hidden',
                    ignore: true
                },
                {
                    key: 'hideLabel',
                    ignore: true
                },
                {
                    key: 'showWordCount',
                    ignore: true
                },
                {
                    key: 'showCharCount',
                    ignore: true
                },
                {
                    key: 'mask',
                    ignore: true
                },
                {
                    key: 'autofocus',
                    ignore: true
                },
                {
                    key: 'disabled',
                    ignore: true
                },
                {
                    key: 'modalEdit',
                    ignore: true
                },
                {
                    key: 'spellcheck',
                    ignore: true
                },
                {
                    key: 'tableView',
                    ignore: true
                }

            ]
          },

            {
                key: 'Advanced',
                label: 'Advanced',
                components: [
                {
                    key: 'MandatoryFlag',
                    input: true,
                    label: 'Is this field Mandatory?',
                    type: 'radio',
                    defaultValue: "N",
                    values: [
                        {
                            "label": "Yes",
                            "value": "Y",
                            "shortcut": ""
                        },
                        {
                            "label": "No",
                            "value": "N",
                            "shortcut": ""
                        }
                    ],
                },
                // {
                //     key: 'MarkIssueFlag',
                //     input: true,
                //     label: 'Mark as on Issue?',
                //     type: 'radio',
                //     defaultValue: "N",
                //     values: [
                //         {
                //             "label": "Yes",
                //             "value": "Y",
                //             "shortcut": ""
                //         },
                //         {
                //             "label": "No",
                //             "value": "N",
                //             "shortcut": ""
                //         }
                //     ],
                // },
                {
                    key: 'SearchFlag',
                    input: true,
                    label: 'Search on this field?',
                    type: 'radio',
                    defaultValue: "N",
                    values: [
                        {
                            "label": "Yes",
                            "value": "Y",
                            "shortcut": ""
                        },
                        {
                            "label": "No",
                            "value": "N",
                            "shortcut": ""
                        }
                    ],
                },
                // {
                //     key: 'PhotoRequiredFlag',
                //     input: true,
                //     label: 'Photo Required',
                //     type: 'select',
                //     //defaultValue: "O",
                //     placeholder: "Select Photo Required",
                //     data: {
                //         values: [
                //             {
                //                 "label": "Required",
                //                 "value": "R"
                //             },
                //             {
                //                 "label": "Optional",
                //                 "value": "O"
                //             },{
                //                 "label": "Defects",
                //                 "value": "D"
                //             },
                //             {
                //                 "label": "Never",
                //                 "value": "N"
                //             }
                //         ]
                //     },
                // },
                // {
                //     key: 'NoOfPhotos',
                //     input: true,
                //     label: 'No of Photos',
                //     type: 'select',
                //     //defaultValue: "O",
                //     placeholder: "Select No of Photos",
                //     data: {
                //         values: [
                //             {
                //                 "label": "1",
                //                 "value": "1"
                //             },
                //             {
                //                 "label": "2",
                //                 "value": "2"
                //             },{
                //                 "label": "3",
                //                 "value": "3"
                //             },
                //             {
                //                 "label": "4",
                //                 "value": "4"
                //             }
                //         ]
                //     },
                // }
                ]
            },
        ],
        number: [
            {
              key: 'validation',
              ignore: true
            },
            {
              key: 'api',
              ignore: true
            },
            {
              key: 'data',
              ignore: true
            },
            {
              key: 'logic',
              ignore: true
            },
            {
              key: 'layout',
              ignore: true
            },
            {
              key: 'conditional',
              ignore: true
            },
            {
              key: 'display',
              label: 'Basic',
              components: [
                  {
                      key: 'tooltip',
                      ignore: true
                  },
                  {
                      key: 'placeholder',
                      ignore: true
                  },
                  {
                      key: 'prefix',
                      ignore: true
                  },
                  {
                      key: 'suffix',
                      ignore: true
                  },
                  {
                      key: 'inputMasks',
                      ignore: true
                  },
                  {
                      key: 'allowMultipleMasks',
                      ignore: true
                  },
                  {
                      key: 'description',
                      ignore: true
                  },
                  {
                      key: 'customClass',
                      ignore: true
                  },
                  {
                      key: 'inputMask',
                      ignore: true
                  },
                  {
                      key: 'tabindex',
                      ignore: true
                  },
                  {
                      key: 'type',
                      ignore: true
                  },
                  {
                      key: 'inputMaskPlaceholderChar',
                      ignore: true
                  },
                  {
                      key: 'labelPosition',
                      ignore: true
                  },
                  {
                      key: 'autocomplete',
                      ignore: true
                  },
                  {
                      key: 'widget.type',
                      ignore: true
                  },
                  {
                      key: 'hidden',
                      ignore: true
                  },
                  {
                      key: 'hideLabel',
                      ignore: true
                  },
                  {
                      key: 'showWordCount',
                      ignore: true
                  },
                  {
                      key: 'showCharCount',
                      ignore: true
                  },
                  {
                      key: 'mask',
                      ignore: true
                  },
                  {
                      key: 'autofocus',
                      ignore: true
                  },
                  {
                      key: 'disabled',
                      ignore: true
                  },
                  {
                      key: 'modalEdit',
                      ignore: true
                  },
                  {
                      key: 'spellcheck',
                      ignore: true
                  },
                  {
                      key: 'tableView',
                      ignore: true
                  }

              ]
            },

              {
                  key: 'Advanced',
                  label: 'Advanced',
                  components: [
                  {
                      key: 'MandatoryFlag',
                      input: true,
                      label: 'Is this field Mandatory?',
                      type: 'radio',
                      defaultValue: "N",
                      values: [
                          {
                              "label": "Yes",
                              "value": "Y",
                              "shortcut": ""
                          },
                          {
                              "label": "No",
                              "value": "N",
                              "shortcut": ""
                          }
                      ],
                  },
                  {
                      key: 'SearchFlag',
                      input: true,
                      label: 'Search on this field?',
                      type: 'radio',
                      defaultValue: "N",
                      values: [
                          {
                              "label": "Yes",
                              "value": "Y",
                              "shortcut": ""
                          },
                          {
                              "label": "No",
                              "value": "N",
                              "shortcut": ""
                          }
                      ],
                  }
                  ]
              },
            {
              key: 'validation',
              components: [
                {
                  key: 'validate.minWords',
                  ignore: true
                },
                {
                  key: 'validate.maxWords',
                  ignore: true
                }
              ]
            },

          ],
        textarea: [
            {
              key: 'validation',
              ignore: true
            },
            {
              key: 'api',
              ignore: true
            },
            {
              key: 'data',
              ignore: true
            },
            {
              key: 'logic',
              ignore: true
            },
            {
              key: 'layout',
              ignore: true
            },
            {
              key: 'conditional',
              ignore: true
            },
            {
              key: 'display',
              label: 'Basic',
              components: [
                    {
                        key: 'editor',
                        ignore: true
                    },
                    {
                        key: 'autoExpand',
                        ignore: true

                    },
                    {
                        key: 'rows',
                        ignore: true

                    },
                  {
                      key: 'tooltip',
                      ignore: true
                  },
                  {
                      key: 'placeholder',
                      ignore: true
                  },
                  {
                      key: 'prefix',
                      ignore: true
                  },
                  {
                      key: 'suffix',
                      ignore: true
                  },
                  {
                      key: 'inputMasks',
                      ignore: true
                  },
                  {
                      key: 'allowMultipleMasks',
                      ignore: true
                  },
                  {
                      key: 'description',
                      ignore: true
                  },
                  {
                      key: 'customClass',
                      ignore: true
                  },
                  {
                      key: 'inputMask',
                      ignore: true
                  },
                  {
                      key: 'tabindex',
                      ignore: true
                  },
                  {
                      key: 'type',
                      ignore: true
                  },
                  {
                      key: 'inputMaskPlaceholderChar',
                      ignore: true
                  },
                  {
                      key: 'labelPosition',
                      ignore: true
                  },
                  {
                      key: 'autocomplete',
                      ignore: true
                  },
                  {
                      key: 'widget.type',
                      ignore: true
                  },
                  {
                      key: 'hidden',
                      ignore: true
                  },
                  {
                      key: 'hideLabel',
                      ignore: true
                  },
                  {
                      key: 'showWordCount',
                      ignore: true
                  },
                  {
                      key: 'showCharCount',
                      ignore: true
                  },
                  {
                      key: 'mask',
                      ignore: true
                  },
                  {
                      key: 'autofocus',
                      ignore: true
                  },
                  {
                      key: 'disabled',
                      ignore: true
                  },
                  {
                      key: 'modalEdit',
                      ignore: true
                  },
                  {
                      key: 'spellcheck',
                      ignore: true
                  },
                  {
                      key: 'tableView',
                      ignore: true
                  }

              ]
            },

              {
                  key: 'Advanced',
                  label: 'Advanced',
                  components: [
                  {
                      key: 'MandatoryFlag',
                      input: true,
                      label: 'Is this field Mandatory?',
                      type: 'radio',
                      defaultValue: "N",
                      values: [
                          {
                              "label": "Yes",
                              "value": "Y",
                              "shortcut": ""
                          },
                          {
                              "label": "No",
                              "value": "N",
                              "shortcut": ""
                          }
                      ],
                  }
                  ]
              },
            {
              key: 'validation',
              components: [
                {
                  key: 'validate.minWords',
                  ignore: true
                },
                {
                  key: 'validate.maxWords',
                  ignore: true
                }
              ]
            },

          ],
       }
      };`
lane-formio commented 8 months ago

We're currently addressing a backlog of GitHub issues, and as part of this effort, some inactive issues may be marked as closed. This isn't a dismissal, but a step toward more efficient tracking.

If you feel the issue is still relevant, please re-open and we'll ensure it gets the attention it deserves. Your understanding is appreciated as we work to enhance our open-source responsiveness.