keystone-classic: Boolean default:true value not working in v4.0.0

Expected behavior

Add a checkbox which is checked by default. Clicking on it should uncheck the box.

Actual/Current behavior

Clicking on the checked by default box does not uncheck it.

Steps to reproduce the actual/current behavior

Add a model with a Boolean field with default value set to true:

import keystone from 'keystone';
const Types = keystone.Field.Types;
const Page = new keystone.List('Page');

Page.add({
	show  : { type: Types.Boolean, label: 'Show this page?', default: true, initial: true }
});
Page.register();

Try and uncheck the checkbox.

Environment

Software Version
Keystone 4.0.0
Node.js 9.3.0
Browser Chrome 67

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 4
  • Comments: 16 (11 by maintainers)

Commits related to this issue

Most upvoted comments

Seeing same issue. Works fine on RC1

Made a PR that will fix the issue.

Guys, this issue was submitted on July 26. It’s still reproduced and that’s a problem for some releases. Will it be fixed in nearest future?