chore: Introduce feature state manager in the extension

Description

This MR adds Feature state manager to the extension that listens for the notification from the Language Server about the features state changes and emits state changes to its subscribers

Related Issues

References #1678 (closed)

How has this been tested?

There are no expected user-facing changes:

To test that the LS feature state changes are reflected in the extension:

LS should be enabled in the extension

  • Scenario 1: Toggle code suggestions for the language, the status icon should be updated accordingly
  • Scenario 2: Open a project without Duo access => Go to Extension settings and find Gitlab › Duo: Enabled Without Gitlab Project => toggle it on and off. Both chat and code suggestions should be disabled when the flag is OFF and enabled when it is ON.

What CHANGELOG entry will this MR create?

  • fix: Bug fix fixes - a user-facing issue in production - included in changelog
  • feature: New feature - a user-facing change which adds functionality - included in changelog
  • BREAKING CHANGE: (fix or feature that would cause existing functionality to change) - should bump major version, mentioned in the changelog
  • None - other non-user-facing changes
Edited by Olena Horal-Koretska

Merge request reports

Loading