Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to remove individual options (such as Display/Label Position or Data/Persistent). #1047

Open
iceman-fx opened this issue Jan 23, 2024 · 1 comment
Labels

Comments

@iceman-fx
Copy link

iceman-fx commented Jan 23, 2024

Hello.
How can you remove individual options in the components so that only the most important settings are displayed?

I've already tried this, but I can't remove the "Label Position" option:

Formio.builder(document.getElementById('builder'), {}, {
  builder: {
    basic: false,
    advanced: false,
    data: false,
    layout: false,
    premium: false,
    
    customBasic: {
      title: 'Formularfelder',
      default: true,
      weight: 0,
      components: {
        textfield: true,
        textarea: true,
        email: true,
        phoneNumber: true
      }
    }
    
  },
  
  editForm: {
    textfield: [
      { key: 'api', ignore: true },
      { key: 'logic', ignore: true },
      { key: 'layout', ignore: true },
      { key: 'conditional', ignore: true },
      { key: 'labelPosition', ignore: true },
      { key: 'display.labelPosition', ignore: true },
      { labelPosition: false },
    ]
  }
  
}).then(function(builder) {
  builder.on('saveComponent', function() {
    console.log(builder.schema);
  });
});

Is there somehow an overview of the “key” names used?

@Ugurercin
Copy link

I have been looking for the same answer. Any updates on this one ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants