Files
threshold-ui/ui/desktop/app/controllers/scopes/scope/projects/targets/target.js
T
Lisbet Alvarez bac3593b97 fix: 🐛 host modal renders whenever there is an error during connection (#1936)
* fix: 🐛 host modal renders whenever there is an error

✅ Closes: ICU-11231

* test: 💍 add test case to make sure fix is working properly

* fix: 🐛 toggle flag back to false and remove @tracked

* fix: 🐛 host modal should also close after host connection error

* refactor: 💡 change toggle to toggleModal

* test: 💍 rename toggle in test cases
2023-10-02 07:26:10 -05:00

24 lines
488 B
JavaScript

/**
* Copyright (c) HashiCorp, Inc.
* SPDX-License-Identifier: MPL-2.0
*/
import Controller from '@ember/controller';
import { tracked } from '@glimmer/tracking';
import { action } from '@ember/object';
export default class ScopesScopeProjectsTargetsTargetController extends Controller {
// =attributes
queryParams = [{ isConnecting: { type: 'boolean' } }];
@tracked isConnecting = false;
// =methods
@action
toggleModal(value) {
this.isConnecting = value;
}
}