Allow Tours to be taken by users that cannot access the Toolbar (e.g. anonymous users)

Created on 19 August 2013, over 11 years ago
Updated 9 September 2024, 3 months ago

Problem/Motivation

Anonymous users cannot start Tours. Currently Tours can only be started by clicking a button in the toolbar, and typically anonymous users have no permission to access the toolbar.

Proposed resolution

Provide a block with a button to start a Tour. This block can then be freely placed anywhere in the website.

How to test

  1. Grant permission to access tours and the views UI (lol) to the authenticated and/or anonymous user role.
  2. Place the block in the sidebar.
  3. Log in as a test user and visit admin/structure/views.
  4. Click on a view to access it.
  5. Click the tour button in the sidebar.
  6. Or visit ie http://drupal.d8/admin/structure/views/view/frontpage?tour=1 (as both authenticated or anonymous

Remaining tasks

User interface changes

None.

API changes

None.

Data model changes

None.

Original report by clemens.tolboom

As the tour icon is only available on the Toolbar anonymous users must get access to the Tour icon.

Without the 'Use the administration toolbar' the tour code is not loaded on the page so even an auto start like http://drupal.d8/?tour=1 fails.

Having the toolbar enabled the user get an access denied for the 'Menu' button.

โœจ Feature request
Status

Fixed

Version

2.0

Component
Tourย  โ†’

Last updated 9 days ago

Created by

๐Ÿ‡ณ๐Ÿ‡ฑNetherlands clemens.tolboom Groningen, ๐Ÿ‡ณ๐Ÿ‡ฑ/๐Ÿ‡ช๐Ÿ‡บ

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone

    This extension is being deprecated, see ๐ŸŒฑ [Meta] Tasks to deprecate Tour module Fixed . It will be removed from core and moved to a contrib project, ๐Ÿ“Œ [11.x] [Meta] Tasks to remove Tour Postponed .

    This is now Postponed. The status is set according to two policies. The Remove a core extension and move it to a contributed project โ†’ and the Extensions approved for removal โ†’ policies.

  • Status changed to Needs work 8 months ago
  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone
  • Assigned to smustgrave
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Letโ€™s land this one

  • Status changed to Needs review 4 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Had to change a number of things around but what about this?

  • ๐Ÿ‡ฉ๐Ÿ‡ชGermany rkoller Nรผrnberg, Germany

    I've retested this another time. Before things had worked both for anonymous users and my admin account. but now with ๐Ÿ› Route parameters appear broken Fixed in when i've retried things, tours were available for my admin user but not for an anonymous user. my setup was:

    • gave the
      access tours</coder> permission to anon, authenticated, content editor and admin role</li>
        <li>created to tours one with the route </li>
      </ul>
      
      <code>entity.node.canonical
      - node:1

      the other

      entity.node.canonical
      - node:2
      • created two nodes
      • on admin/structure/block i've added the Tour button to the header section in olivero

      the problems are:

      1. both tours are available for the admin role while both tours are not available for the anonymous role in a private window.
      2. when i place and save the tour button block on the block layout page (either for claro or olivero) the tour for the block layout page is auto started. that doesnt happen when i try to add any other block. and the start of the tour happens again if i add the tour button another time
  • Issue was unassigned.
  • Status changed to Needs work 4 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Sounds like needs slightly more work.

    Will try and find time next week but un-assigning incase anyone wants a crack.

  • Status changed to Needs review 4 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    both tours are available for the admin role while both tours are not available for the anonymous role in a private window.

    Wouldn't that be correct? Purpose of adding the block is so it can be blocked outside the toolbar. If anonymous doesn't have access to the toolbar they shouldn't have access to the content there.

    when i place and save the tour button block on the block layout page (either for claro or olivero) the tour for the block layout page is auto started. that doesnt happen when i try to add any other block. and the start of the tour happens again if i add the tour button another time

    actually seems like it was a bug with the js where it wasn't checking for "tour=" but just looking for "tour" which the block name triggered.

  • ๐Ÿ‡ฉ๐Ÿ‡ชGermany rkoller Nรผrnberg, Germany

    #117.2 got fixed after pulling the latest changes. looks good!

    #117.1 hmm i have given the access tour permission to anonymous, authenticated, content editor and administrator. and the route for the test tour is

    entity.node.canonical
    - node:2

    and i have added the tour button in the header section of the block layout page.that is my setting. now:

    Wouldn't that be correct? Purpose of adding the block is so it can be blocked outside the toolbar. If anonymous doesn't have access to the toolbar they shouldn't have access to the content there.

    but isnt the issue title Allow Tours to be taken by users that cannot access the Toolbar (e.g. anonymous users) so my expectation would be that me as an anonymous user who has the permission to access a tour and not the toolbar would also be able to start a tour by clicking the take a tour of this page button? but the results are:

    anonymous:
    clicking the take a tour button on node 4 in olivero -> no effect
    clicking the take a tour button on node 2 in olivero -> no effect (even though there is a tour available)

    admin (with admin_toolbar shown)
    clicking the take a tour button on node 4 in olivero not the admin_toolbar-> no effect
    clicking the take a tour button on node 4 in olivero not the admin_toolbar -> the tour is shown. position for the tip is right and the tip gets somehow hidden and inaccessible underneath the admin_toolbar in part. mouse users would be unable to access the close button

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    No I think that other issue title isnโ€™t correct. That ticket we decoupled the toolbar classes from tour.

    I donโ€™t know of any feature thatโ€™s in the toolbar that anonymous users have access to.

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave
  • Status changed to Fixed 4 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024