Any recommendations on how I can support adding indicator for anonymous user or user without access to toolbar

Created on 27 February 2023, over 2 years ago

Problem/Motivation

As stated, I am looking into options on how I can still show an environment indicator even when a user is not logged in or when a user is logged in but don't have access to toolbar.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

✨ Feature request
Status

Active

Version

4.0

Component

Miscellaneous

Created by

πŸ‡ΊπŸ‡ΈUnited States robpowell Boston

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

Comments & Activities

  • Issue created by @robpowell
  • @robpowell opened merge request.
  • πŸ‡ΊπŸ‡ΈUnited States robpowell Boston

    I've gone ahead and created a submodule, environment_indicator_block. If the maintainers rather this as a separate module please let me know.

    One outstanding question, I am managing my indicator values through hardcoding them in the settings file:

    # Site environment
    $config['environment_indicator.indicator']['name'] = 'LOCAL';
    $config['environment_indicator.indicator']['bg_color'] = '#8A1350';
    $config['environment_indicator.indicator']['fg_color'] = '#FFFFFF';
    

    For my setup, it doesn't seem like I need to add any cacheable metadata to the block because it will require a cache rebuild to get the overrides, right? What would be a good way to future proof it a bit?

    Here are some screenshots of the block in action



  • Status changed to Needs review over 2 years ago
  • πŸ‡ΊπŸ‡ΈUnited States robpowell Boston
  • Status changed to Closed: outdated 9 days ago
  • πŸ‡¨πŸ‡¦Canada colan Toronto πŸ‡¨πŸ‡¦

    There are permissions for each environment now, and you can turn off the toolbar feature (so it show up by itself).

Production build 0.71.5 2024