github payloadcms/payload v3.0.0-beta.105

latest releases: v3.0.0-beta.107, v3.0.0-beta.106
pre-release3 days ago

v3.0.0-beta.105 (2024-09-15)

⚡ Performance

  • upgrade ajv, and upgrade typescript to 5.6.2 in monorepo (#8204) (fbc28b0)
  • upgrade jsonwebtoken from 9.0.1 to 9.0.2 (#8202) (ec624bd)

🐛 Bug Fixes

  • plugin-seo: removes duplicative json translations (#8206) (64f2395)
  • error when viewing versions if plural label is set as a function (#8213) (ff1c1e0)
  • richtext-lexical: default Cell not being a link when used as the primary column in lists (#8212) (d0bb1c9)
  • ui: field type being overridden when providing a Cell component (#8211) (1608150)
  • db-postgres: preserve parent createdAt when creating a new version (#8160) (43a9109)
  • richtext-lexical: unnecessary isEnabled computations on toolbar items (#8176) (334f940)
  • graphql: id field non null (#8169) (db29e1e)
  • ui: bulk selection and useSelection hook losing types of the IDs its returning (#8194) (d28d40c)
  • ui: properly extracts label from field in FieldLabel component (#8190) (a6f13f7)
  • requires client field prop in server field components (#8188) (c28618b)

⚠️ BREAKING CHANGES

  • ui: bulk selection and useSelection hook losing types of the IDs its returning (#8194) (d28d40c)

This PR changes the type of selected returned from the useSelection
hook from the SelectionProvider from an object to a Map.

This fixes a bug where in some situations we lose the type of the ID
which can break data entry when using postgres, due to keys being cast
to strings inside of objects which doesn't happen when using a Map.

This PR also fixes a CSS bug with the checkbox when it should be
partially selected.

// before
selected: Record<number | string, boolean>

// after
selected: Map<number | string, boolean>

This means you now need to read the data differently than before.

// before
Object.entries(selected).forEach(([key, value]) => {
  // do something
})

// after
for (const [key, value] of selected) {
  // do something
}

🤝 Contributors

Don't miss a new payload release

NewReleases is sending notifications on new releases.