2026.5.2
Full Changelog: 2026.5.1...2026.5.2
New: cross-level filtering in nested formsets
FilterSpec now takes a levels_up argument:
FilterSpec(source="customer", lookup="id", source_type="field", levels_up=1)This lets a select inside an inner formset row pull its filter value from a field on the outer parent row. levels_up=0 (the default) is the original same-row behavior, so existing configs aren't affected. Only valid on source_type="field". See docs/api/config.md for the full writeup.
If existing projects override tomselect.html
A few things were changed:
resetTomSelectStatenow takes one argument:(tomSelect). It readsoriginalFirstUrland the reset-flag name offtomSelect.settings.- Per-instance state lives on the TomSelect instance:
this._previousQuery,this._currentLoadController. The old IIFE-scopedpreviousQueryandcurrentLoadControllerare gone - they were the source of cross-row leaks in formsets. - The config now ships
settings.resetVarNameandsettings.originalFirstUrl, andshouldLoad/load/ reset all consume them. onItemAdd,onItemRemove,onDropdownOpen,onDropdownCloseusethis.inputinstead of the closure-capturedelementso cloned rows target their own select.- The dead
{% if 'render' in widget.attrs.keys ... %}block at the bottom of the template was removed. It had been unreachable sincerenderis popped from attrs before render.