The previous iteration of the turbo frame setup, and the attempted fixes in #494, #495 and #497 had some drawbacks still. One of the main ones being that the scopes were outside of the index turbo frame, so scope counts were not being updated when rows were added, deleted or filtered via a search.
This PR:
Backs out #497 and separates .app-main from the #main turbo-frame (it does not feel right for a turbo frame to be a structural element)
Moves the #main turbo-frame inside app/views/trestle/application/_layout.html.erb so that it can be bypassed if required.
Introduces a new #content turbo-frame within app/views/trestle/application/_layout.html.erb that wraps utilities, tabs and content (but not the flash).
Deprecates the #index_turbo_frame helper and removes its usage from the templates. Existing usage should continue to work, essentially functioning as a no-op.
Removes the turbo stream layout file, preferring targeted turbo stream actions within each create/update/destroy response.
coverage: 91.41% (-0.07%) from 91.475%
when pulling 04290d20678d39a0b7c879e7c0b5c4107cbada2a on turbo-frame-refinements
into c8bf8954ab930ed615a790dba674e9f2b7e5db24 on main.
The previous iteration of the turbo frame setup, and the attempted fixes in #494, #495 and #497 had some drawbacks still. One of the main ones being that the scopes were outside of the index turbo frame, so scope counts were not being updated when rows were added, deleted or filtered via a search.
This PR:
.app-main
from the#main
turbo-frame (it does not feel right for a turbo frame to be a structural element)#main
turbo-frame insideapp/views/trestle/application/_layout.html.erb
so that it can be bypassed if required.#content
turbo-frame withinapp/views/trestle/application/_layout.html.erb
that wraps utilities, tabs and content (but not the flash).#index_turbo_frame
helper and removes its usage from the templates. Existing usage should continue to work, essentially functioning as a no-op.