NPM Resource Changed PR-6.3-dev Pending

User tests: Successful: Unsuccessful:

avatar mvanvu
mvanvu
26 Sep 2026

Summary of Changes

The inline help toggle forgets its state on every page load, so anyone who keeps the descriptions open has to press the button again after each save or reload.

This adds an opt-in storage attribute to the form's inline help config:

<config>
    <inlinehelp button="show" storage="local"/>
</config>

When it is set, the toggle state is kept in localStorage, keyed by the toggle class and the page URL (path + query string), so each form remembers its own state. Only the visible state is stored; hiding the help removes the key.

  • FormView::addToolbar() reads storage from the form XML and passes it to the button.
  • InlinehelpButton gets a storage option, rendered as data-storage.
  • inlinehelp.es6.js restores and saves the state only when the button carries data-storage="local". Storage access is wrapped in try/catch, so blocked storage (private mode, disabled site data) falls back to the current behaviour.

Forms without the attribute are unchanged.

Testing Instructions

  1. Apply the PR and run npm run build:js.
  2. In administrator/components/com_content/forms/article.xml, change <inlinehelp button="show"/> to <inlinehelp button="show" storage="local"/>.
  3. Content → Articles → New. Press Toggle Inline Help, then reload the page.
  4. Press Toggle Inline Help again to hide the help, then reload.
  5. Open a form that does not use the attribute (e.g. System → Guided Tours → New), toggle the help on and reload.

Actual result BEFORE applying this Pull Request

The inline help is hidden again after every reload, on every form.

Expected result AFTER applying this Pull Request

  • Step 3: the help is still visible after the reload.
  • Step 4: the help is hidden after the reload and the joomla.inlinehelp.* key is gone from localStorage.
  • Step 5: the help is hidden after the reload and nothing is written to localStorage — unchanged behaviour.

Link to documentations

Please select:

  • Documentation link for guide.joomla.org:
  • No documentation changes for guide.joomla.org needed
  • Pull Request link for manual.joomla.org:
  • No documentation changes for manual.joomla.org needed
avatar mvanvu mvanvu - open - 26 Sep 2026
avatar mvanvu mvanvu - change - 26 Sep 2026
Status New ⇒ Pending
avatar joomla-cms-bot joomla-cms-bot - change - 26 Sep 2026
Category ⇒ Libraries JavaScript NPM Change
avatar brianteeman
brianteeman - comment - 26 Sep 2026

Nice idea

avatar mvanvu mvanvu - change - 26 Sep 2026
Labels Added: NPM Resource Changed PR-6.3-dev

Add a Comment

Login with GitHub to post a comment