Tweak how Torque cache is moved
I was a bad teammate and didn't review !15 (merged) in time. This MR contains what would have been my suggested changes:
- Changes the technique so that the
lfc--outside-cache
andlfc--inside-cache
elements don't share the sameid
attribute, as that's not valid HTML. Instead,lfc--outside-cache
will populate adata-id
attribute. This requires changes to the markup generation not covered by this MR (as I don't know where that happens). - Protects against an
lfc--outside-cache
element with a missingdata-id
attribute. - Rather than append to the destination element -- which implicitly signals it may contain content we need to preserve -- overwrite its contents entirely.
- Add some comments to the CSS.
Again, apologies for not reviewing this properly before!