diff --git a/ui-v2/.ember-cli b/ui-v2/.ember-cli index ee64cfed2..7f520c46a 100644 --- a/ui-v2/.ember-cli +++ b/ui-v2/.ember-cli @@ -5,5 +5,14 @@ Setting `disableAnalytics` to true will prevent any data from being sent. */ - "disableAnalytics": false + "disableAnalytics": false, + /** + We use a nested in /components folder structure: + /components/component-name/index.{hbs,js} + */ + "componentStructure": "nested", + /** + We currently use classic components + */ + "componentClass": "@ember/component" } diff --git a/ui-v2/app/templates/components/acl-filter.hbs b/ui-v2/app/components/acl-filter/index.hbs similarity index 100% rename from ui-v2/app/templates/components/acl-filter.hbs rename to ui-v2/app/components/acl-filter/index.hbs diff --git a/ui-v2/app/components/acl-filter.js b/ui-v2/app/components/acl-filter/index.js similarity index 100% rename from ui-v2/app/components/acl-filter.js rename to ui-v2/app/components/acl-filter/index.js diff --git a/ui-v2/app/templates/components/action-group.hbs b/ui-v2/app/components/action-group/index.hbs similarity index 100% rename from ui-v2/app/templates/components/action-group.hbs rename to ui-v2/app/components/action-group/index.hbs diff --git a/ui-v2/app/components/action-group.js b/ui-v2/app/components/action-group/index.js similarity index 100% rename from ui-v2/app/components/action-group.js rename to ui-v2/app/components/action-group/index.js diff --git a/ui-v2/app/templates/components/app-view.hbs b/ui-v2/app/components/app-view/index.hbs similarity index 100% rename from ui-v2/app/templates/components/app-view.hbs rename to ui-v2/app/components/app-view/index.hbs diff --git a/ui-v2/app/components/app-view.js b/ui-v2/app/components/app-view/index.js similarity index 100% rename from ui-v2/app/components/app-view.js rename to ui-v2/app/components/app-view/index.js diff --git a/ui-v2/app/templates/components/aria-menu.hbs b/ui-v2/app/components/aria-menu/index.hbs similarity index 100% rename from ui-v2/app/templates/components/aria-menu.hbs rename to ui-v2/app/components/aria-menu/index.hbs diff --git a/ui-v2/app/components/aria-menu.js b/ui-v2/app/components/aria-menu/index.js similarity index 100% rename from ui-v2/app/components/aria-menu.js rename to ui-v2/app/components/aria-menu/index.js diff --git a/ui-v2/app/templates/components/catalog-filter.hbs b/ui-v2/app/components/catalog-filter/index.hbs similarity index 100% rename from ui-v2/app/templates/components/catalog-filter.hbs rename to ui-v2/app/components/catalog-filter/index.hbs diff --git a/ui-v2/app/components/catalog-filter.js b/ui-v2/app/components/catalog-filter/index.js similarity index 100% rename from ui-v2/app/components/catalog-filter.js rename to ui-v2/app/components/catalog-filter/index.js diff --git a/ui-v2/app/templates/components/changeable-set.hbs b/ui-v2/app/components/changeable-set/index.hbs similarity index 100% rename from ui-v2/app/templates/components/changeable-set.hbs rename to ui-v2/app/components/changeable-set/index.hbs diff --git a/ui-v2/app/components/changeable-set.js b/ui-v2/app/components/changeable-set/index.js similarity index 100% rename from ui-v2/app/components/changeable-set.js rename to ui-v2/app/components/changeable-set/index.js diff --git a/ui-v2/app/templates/components/child-selector.hbs b/ui-v2/app/components/child-selector/index.hbs similarity index 100% rename from ui-v2/app/templates/components/child-selector.hbs rename to ui-v2/app/components/child-selector/index.hbs diff --git a/ui-v2/app/components/child-selector.js b/ui-v2/app/components/child-selector/index.js similarity index 100% rename from ui-v2/app/components/child-selector.js rename to ui-v2/app/components/child-selector/index.js diff --git a/ui-v2/app/templates/components/code-editor.hbs b/ui-v2/app/components/code-editor/index.hbs similarity index 100% rename from ui-v2/app/templates/components/code-editor.hbs rename to ui-v2/app/components/code-editor/index.hbs diff --git a/ui-v2/app/components/code-editor.js b/ui-v2/app/components/code-editor/index.js similarity index 100% rename from ui-v2/app/components/code-editor.js rename to ui-v2/app/components/code-editor/index.js diff --git a/ui-v2/app/templates/components/confirmation-dialog.hbs b/ui-v2/app/components/confirmation-dialog/index.hbs similarity index 100% rename from ui-v2/app/templates/components/confirmation-dialog.hbs rename to ui-v2/app/components/confirmation-dialog/index.hbs diff --git a/ui-v2/app/components/confirmation-dialog.js b/ui-v2/app/components/confirmation-dialog/index.js similarity index 100% rename from ui-v2/app/components/confirmation-dialog.js rename to ui-v2/app/components/confirmation-dialog/index.js diff --git a/ui-v2/app/templates/components/consul-service-list.hbs b/ui-v2/app/components/consul-service-list/index.hbs similarity index 100% rename from ui-v2/app/templates/components/consul-service-list.hbs rename to ui-v2/app/components/consul-service-list/index.hbs diff --git a/ui-v2/app/components/consul-service-list.js b/ui-v2/app/components/consul-service-list/index.js similarity index 100% rename from ui-v2/app/components/consul-service-list.js rename to ui-v2/app/components/consul-service-list/index.js diff --git a/ui-v2/app/templates/components/copy-button-feedback.hbs b/ui-v2/app/components/copy-button-feedback/index.hbs similarity index 100% rename from ui-v2/app/templates/components/copy-button-feedback.hbs rename to ui-v2/app/components/copy-button-feedback/index.hbs diff --git a/ui-v2/app/components/copy-button-feedback.js b/ui-v2/app/components/copy-button-feedback/index.js similarity index 100% rename from ui-v2/app/components/copy-button-feedback.js rename to ui-v2/app/components/copy-button-feedback/index.js diff --git a/ui-v2/app/templates/components/copy-button.hbs b/ui-v2/app/components/copy-button/index.hbs similarity index 100% rename from ui-v2/app/templates/components/copy-button.hbs rename to ui-v2/app/components/copy-button/index.hbs diff --git a/ui-v2/app/components/copy-button.js b/ui-v2/app/components/copy-button/index.js similarity index 100% rename from ui-v2/app/components/copy-button.js rename to ui-v2/app/components/copy-button/index.js diff --git a/ui-v2/app/templates/components/delete-confirmation.hbs b/ui-v2/app/components/delete-confirmation/index.hbs similarity index 100% rename from ui-v2/app/templates/components/delete-confirmation.hbs rename to ui-v2/app/components/delete-confirmation/index.hbs diff --git a/ui-v2/app/components/delete-confirmation.js b/ui-v2/app/components/delete-confirmation/index.js similarity index 100% rename from ui-v2/app/components/delete-confirmation.js rename to ui-v2/app/components/delete-confirmation/index.js diff --git a/ui-v2/app/templates/components/discovery-chain.hbs b/ui-v2/app/components/discovery-chain/index.hbs similarity index 100% rename from ui-v2/app/templates/components/discovery-chain.hbs rename to ui-v2/app/components/discovery-chain/index.hbs diff --git a/ui-v2/app/components/discovery-chain.js b/ui-v2/app/components/discovery-chain/index.js similarity index 100% rename from ui-v2/app/components/discovery-chain.js rename to ui-v2/app/components/discovery-chain/index.js diff --git a/ui-v2/app/templates/components/dom-buffer-flush.hbs b/ui-v2/app/components/dom-buffer-flush/index.hbs similarity index 100% rename from ui-v2/app/templates/components/dom-buffer-flush.hbs rename to ui-v2/app/components/dom-buffer-flush/index.hbs diff --git a/ui-v2/app/components/dom-buffer-flush.js b/ui-v2/app/components/dom-buffer-flush/index.js similarity index 100% rename from ui-v2/app/components/dom-buffer-flush.js rename to ui-v2/app/components/dom-buffer-flush/index.js diff --git a/ui-v2/app/templates/components/dom-buffer.hbs b/ui-v2/app/components/dom-buffer/index.hbs similarity index 100% rename from ui-v2/app/templates/components/dom-buffer.hbs rename to ui-v2/app/components/dom-buffer/index.hbs diff --git a/ui-v2/app/components/dom-buffer.js b/ui-v2/app/components/dom-buffer/index.js similarity index 100% rename from ui-v2/app/components/dom-buffer.js rename to ui-v2/app/components/dom-buffer/index.js diff --git a/ui-v2/app/templates/components/feedback-dialog.hbs b/ui-v2/app/components/feedback-dialog/index.hbs similarity index 100% rename from ui-v2/app/templates/components/feedback-dialog.hbs rename to ui-v2/app/components/feedback-dialog/index.hbs diff --git a/ui-v2/app/components/feedback-dialog.js b/ui-v2/app/components/feedback-dialog/index.js similarity index 100% rename from ui-v2/app/components/feedback-dialog.js rename to ui-v2/app/components/feedback-dialog/index.js diff --git a/ui-v2/app/templates/components/form-component.hbs b/ui-v2/app/components/form-component/index.hbs similarity index 100% rename from ui-v2/app/templates/components/form-component.hbs rename to ui-v2/app/components/form-component/index.hbs diff --git a/ui-v2/app/components/form-component.js b/ui-v2/app/components/form-component/index.js similarity index 100% rename from ui-v2/app/components/form-component.js rename to ui-v2/app/components/form-component/index.js diff --git a/ui-v2/app/templates/components/freetext-filter.hbs b/ui-v2/app/components/freetext-filter/index.hbs similarity index 100% rename from ui-v2/app/templates/components/freetext-filter.hbs rename to ui-v2/app/components/freetext-filter/index.hbs diff --git a/ui-v2/app/components/freetext-filter.js b/ui-v2/app/components/freetext-filter/index.js similarity index 100% rename from ui-v2/app/components/freetext-filter.js rename to ui-v2/app/components/freetext-filter/index.js diff --git a/ui-v2/app/templates/components/hashicorp-consul.hbs b/ui-v2/app/components/hashicorp-consul/index.hbs similarity index 100% rename from ui-v2/app/templates/components/hashicorp-consul.hbs rename to ui-v2/app/components/hashicorp-consul/index.hbs diff --git a/ui-v2/app/components/hashicorp-consul.js b/ui-v2/app/components/hashicorp-consul/index.js similarity index 100% rename from ui-v2/app/components/hashicorp-consul.js rename to ui-v2/app/components/hashicorp-consul/index.js diff --git a/ui-v2/app/templates/components/healthcheck-info.hbs b/ui-v2/app/components/healthcheck-info/index.hbs similarity index 100% rename from ui-v2/app/templates/components/healthcheck-info.hbs rename to ui-v2/app/components/healthcheck-info/index.hbs diff --git a/ui-v2/app/components/healthcheck-info.js b/ui-v2/app/components/healthcheck-info/index.js similarity index 100% rename from ui-v2/app/components/healthcheck-info.js rename to ui-v2/app/components/healthcheck-info/index.js diff --git a/ui-v2/app/templates/components/healthcheck-list.hbs b/ui-v2/app/components/healthcheck-list/index.hbs similarity index 100% rename from ui-v2/app/templates/components/healthcheck-list.hbs rename to ui-v2/app/components/healthcheck-list/index.hbs diff --git a/ui-v2/app/components/healthcheck-list.js b/ui-v2/app/components/healthcheck-list/index.js similarity index 100% rename from ui-v2/app/components/healthcheck-list.js rename to ui-v2/app/components/healthcheck-list/index.js diff --git a/ui-v2/app/templates/components/healthcheck-output.hbs b/ui-v2/app/components/healthcheck-output/index.hbs similarity index 100% rename from ui-v2/app/templates/components/healthcheck-output.hbs rename to ui-v2/app/components/healthcheck-output/index.hbs diff --git a/ui-v2/app/components/healthcheck-output.js b/ui-v2/app/components/healthcheck-output/index.js similarity index 100% rename from ui-v2/app/components/healthcheck-output.js rename to ui-v2/app/components/healthcheck-output/index.js diff --git a/ui-v2/app/templates/components/healthcheck-status.hbs b/ui-v2/app/components/healthcheck-status/index.hbs similarity index 100% rename from ui-v2/app/templates/components/healthcheck-status.hbs rename to ui-v2/app/components/healthcheck-status/index.hbs diff --git a/ui-v2/app/components/healthcheck-status.js b/ui-v2/app/components/healthcheck-status/index.js similarity index 100% rename from ui-v2/app/components/healthcheck-status.js rename to ui-v2/app/components/healthcheck-status/index.js diff --git a/ui-v2/app/templates/components/healthchecked-resource.hbs b/ui-v2/app/components/healthchecked-resource/index.hbs similarity index 100% rename from ui-v2/app/templates/components/healthchecked-resource.hbs rename to ui-v2/app/components/healthchecked-resource/index.hbs diff --git a/ui-v2/app/components/healthchecked-resource.js b/ui-v2/app/components/healthchecked-resource/index.js similarity index 100% rename from ui-v2/app/components/healthchecked-resource.js rename to ui-v2/app/components/healthchecked-resource/index.js diff --git a/ui-v2/app/templates/components/intention-filter.hbs b/ui-v2/app/components/intention-filter/index.hbs similarity index 100% rename from ui-v2/app/templates/components/intention-filter.hbs rename to ui-v2/app/components/intention-filter/index.hbs diff --git a/ui-v2/app/components/intention-filter.js b/ui-v2/app/components/intention-filter/index.js similarity index 100% rename from ui-v2/app/components/intention-filter.js rename to ui-v2/app/components/intention-filter/index.js diff --git a/ui-v2/app/templates/components/list-collection.hbs b/ui-v2/app/components/list-collection/index.hbs similarity index 100% rename from ui-v2/app/templates/components/list-collection.hbs rename to ui-v2/app/components/list-collection/index.hbs diff --git a/ui-v2/app/components/list-collection.js b/ui-v2/app/components/list-collection/index.js similarity index 100% rename from ui-v2/app/components/list-collection.js rename to ui-v2/app/components/list-collection/index.js diff --git a/ui-v2/app/templates/components/modal-dialog.hbs b/ui-v2/app/components/modal-dialog/index.hbs similarity index 100% rename from ui-v2/app/templates/components/modal-dialog.hbs rename to ui-v2/app/components/modal-dialog/index.hbs diff --git a/ui-v2/app/components/modal-dialog.js b/ui-v2/app/components/modal-dialog/index.js similarity index 100% rename from ui-v2/app/components/modal-dialog.js rename to ui-v2/app/components/modal-dialog/index.js diff --git a/ui-v2/app/templates/components/modal-layer.hbs b/ui-v2/app/components/modal-layer/index.hbs similarity index 100% rename from ui-v2/app/templates/components/modal-layer.hbs rename to ui-v2/app/components/modal-layer/index.hbs diff --git a/ui-v2/app/components/modal-layer.js b/ui-v2/app/components/modal-layer/index.js similarity index 100% rename from ui-v2/app/components/modal-layer.js rename to ui-v2/app/components/modal-layer/index.js diff --git a/ui-v2/app/templates/components/phrase-editor.hbs b/ui-v2/app/components/phrase-editor/index.hbs similarity index 100% rename from ui-v2/app/templates/components/phrase-editor.hbs rename to ui-v2/app/components/phrase-editor/index.hbs diff --git a/ui-v2/app/components/phrase-editor.js b/ui-v2/app/components/phrase-editor/index.js similarity index 100% rename from ui-v2/app/components/phrase-editor.js rename to ui-v2/app/components/phrase-editor/index.js diff --git a/ui-v2/app/templates/components/policy-form.hbs b/ui-v2/app/components/policy-form/index.hbs similarity index 91% rename from ui-v2/app/templates/components/policy-form.hbs rename to ui-v2/app/components/policy-form/index.hbs index fc8300dbc..fe5e7cf3d 100644 --- a/ui-v2/app/templates/components/policy-form.hbs +++ b/ui-v2/app/components/policy-form/index.hbs @@ -12,9 +12,9 @@ {{! this should use radio-group }}
{{#each templates as |template|}} -
diff --git a/ui-v2/app/components/policy-form.js b/ui-v2/app/components/policy-form/index.js similarity index 96% rename from ui-v2/app/components/policy-form.js rename to ui-v2/app/components/policy-form/index.js index cbd7cd13a..84a8f01f6 100644 --- a/ui-v2/app/components/policy-form.js +++ b/ui-v2/app/components/policy-form/index.js @@ -1,4 +1,4 @@ -import FormComponent from './form-component'; +import FormComponent from '../form-component/index'; import { inject as service } from '@ember/service'; import { get, set } from '@ember/object'; diff --git a/ui-v2/app/templates/components/policy-selector.hbs b/ui-v2/app/components/policy-selector/index.hbs similarity index 91% rename from ui-v2/app/templates/components/policy-selector.hbs rename to ui-v2/app/components/policy-selector/index.hbs index c4deb23c5..ca122241e 100644 --- a/ui-v2/app/templates/components/policy-selector.hbs +++ b/ui-v2/app/components/policy-selector/index.hbs @@ -12,7 +12,11 @@ {{!TODO: potentially call trigger something else}} {{!the modal has to go here so that if you provide a slot to trigger it doesn't get rendered}} - {{#modal-dialog data-test-policy-form onopen=(action 'open') name="new-policy-toggle"}} +

New Policy

@@ -28,18 +32,18 @@ - {{/modal-dialog}} +
{{/yield-slot}} {{option.Name}} - {{#tabular-details + Name Datacenters @@ -83,7 +87,7 @@ - {{/tabular-details}} + diff --git a/ui-v2/app/components/policy-selector.js b/ui-v2/app/components/policy-selector/index.js similarity index 97% rename from ui-v2/app/components/policy-selector.js rename to ui-v2/app/components/policy-selector/index.js index a36115af0..f2c43b09f 100644 --- a/ui-v2/app/components/policy-selector.js +++ b/ui-v2/app/components/policy-selector/index.js @@ -1,4 +1,4 @@ -import ChildSelectorComponent from './child-selector'; +import ChildSelectorComponent from '../child-selector/index'; import { get, set } from '@ember/object'; import { inject as service } from '@ember/service'; import updateArrayObject from 'consul-ui/utils/update-array-object'; diff --git a/ui-v2/app/templates/components/popover-menu.hbs b/ui-v2/app/components/popover-menu/index.hbs similarity index 100% rename from ui-v2/app/templates/components/popover-menu.hbs rename to ui-v2/app/components/popover-menu/index.hbs diff --git a/ui-v2/app/components/popover-menu.js b/ui-v2/app/components/popover-menu/index.js similarity index 100% rename from ui-v2/app/components/popover-menu.js rename to ui-v2/app/components/popover-menu/index.js diff --git a/ui-v2/app/templates/components/radio-group.hbs b/ui-v2/app/components/radio-group/index.hbs similarity index 100% rename from ui-v2/app/templates/components/radio-group.hbs rename to ui-v2/app/components/radio-group/index.hbs diff --git a/ui-v2/app/components/radio-group.js b/ui-v2/app/components/radio-group/index.js similarity index 100% rename from ui-v2/app/components/radio-group.js rename to ui-v2/app/components/radio-group/index.js diff --git a/ui-v2/app/templates/components/resolver-card.hbs b/ui-v2/app/components/resolver-card/index.hbs similarity index 100% rename from ui-v2/app/templates/components/resolver-card.hbs rename to ui-v2/app/components/resolver-card/index.hbs diff --git a/ui-v2/app/components/resolver-card.js b/ui-v2/app/components/resolver-card/index.js similarity index 100% rename from ui-v2/app/components/resolver-card.js rename to ui-v2/app/components/resolver-card/index.js diff --git a/ui-v2/app/templates/components/role-form.hbs b/ui-v2/app/components/role-form/index.hbs similarity index 100% rename from ui-v2/app/templates/components/role-form.hbs rename to ui-v2/app/components/role-form/index.hbs diff --git a/ui-v2/app/components/role-form.js b/ui-v2/app/components/role-form/index.js similarity index 66% rename from ui-v2/app/components/role-form.js rename to ui-v2/app/components/role-form/index.js index 5ebe540c9..3b8a80279 100644 --- a/ui-v2/app/components/role-form.js +++ b/ui-v2/app/components/role-form/index.js @@ -1,4 +1,4 @@ -import FormComponent from './form-component'; +import FormComponent from '../form-component/index'; export default FormComponent.extend({ type: 'role', name: 'role', diff --git a/ui-v2/app/templates/components/role-selector.hbs b/ui-v2/app/components/role-selector/index.hbs similarity index 94% rename from ui-v2/app/templates/components/role-selector.hbs rename to ui-v2/app/components/role-selector/index.hbs index c24a7f022..6be733593 100644 --- a/ui-v2/app/templates/components/role-selector.hbs +++ b/ui-v2/app/components/role-selector/index.hbs @@ -1,4 +1,8 @@ -{{#modal-dialog data-test-role-form onclose=(action (mut state) 'role') name="new-role-toggle"}} + {{#if (eq state 'role')}}

New Role

@@ -48,7 +52,7 @@ {{/if}}
-{{/modal-dialog}} +
@@ -64,11 +68,11 @@ {{option.Name}} - {{#tabular-collection + Name Description @@ -116,6 +120,6 @@ - {{/tabular-collection}} + diff --git a/ui-v2/app/components/role-selector.js b/ui-v2/app/components/role-selector/index.js similarity index 95% rename from ui-v2/app/components/role-selector.js rename to ui-v2/app/components/role-selector/index.js index 574e6ec8a..05a024453 100644 --- a/ui-v2/app/components/role-selector.js +++ b/ui-v2/app/components/role-selector/index.js @@ -1,4 +1,4 @@ -import ChildSelectorComponent from './child-selector'; +import ChildSelectorComponent from '../child-selector/index'; import { inject as service } from '@ember/service'; import { set } from '@ember/object'; import { alias } from '@ember/object/computed'; diff --git a/ui-v2/app/templates/components/route-card.hbs b/ui-v2/app/components/route-card/index.hbs similarity index 100% rename from ui-v2/app/templates/components/route-card.hbs rename to ui-v2/app/components/route-card/index.hbs diff --git a/ui-v2/app/components/route-card.js b/ui-v2/app/components/route-card/index.js similarity index 100% rename from ui-v2/app/components/route-card.js rename to ui-v2/app/components/route-card/index.js diff --git a/ui-v2/app/templates/components/secret-button.hbs b/ui-v2/app/components/secret-button/index.hbs similarity index 100% rename from ui-v2/app/templates/components/secret-button.hbs rename to ui-v2/app/components/secret-button/index.hbs diff --git a/ui-v2/app/components/secret-button.js b/ui-v2/app/components/secret-button/index.js similarity index 100% rename from ui-v2/app/components/secret-button.js rename to ui-v2/app/components/secret-button/index.js diff --git a/ui-v2/app/templates/components/service-identity.hbs b/ui-v2/app/components/service-identity/index.hbs similarity index 100% rename from ui-v2/app/templates/components/service-identity.hbs rename to ui-v2/app/components/service-identity/index.hbs diff --git a/ui-v2/app/components/service-identity.js b/ui-v2/app/components/service-identity/index.js similarity index 100% rename from ui-v2/app/components/service-identity.js rename to ui-v2/app/components/service-identity/index.js diff --git a/ui-v2/app/templates/components/sort-control.hbs b/ui-v2/app/components/sort-control/index.hbs similarity index 100% rename from ui-v2/app/templates/components/sort-control.hbs rename to ui-v2/app/components/sort-control/index.hbs diff --git a/ui-v2/app/components/sort-control.js b/ui-v2/app/components/sort-control/index.js similarity index 100% rename from ui-v2/app/components/sort-control.js rename to ui-v2/app/components/sort-control/index.js diff --git a/ui-v2/app/templates/components/splitter-card.hbs b/ui-v2/app/components/splitter-card/index.hbs similarity index 100% rename from ui-v2/app/templates/components/splitter-card.hbs rename to ui-v2/app/components/splitter-card/index.hbs diff --git a/ui-v2/app/components/splitter-card.js b/ui-v2/app/components/splitter-card/index.js similarity index 100% rename from ui-v2/app/components/splitter-card.js rename to ui-v2/app/components/splitter-card/index.js diff --git a/ui-v2/app/templates/components/stats-card.hbs b/ui-v2/app/components/stats-card/index.hbs similarity index 100% rename from ui-v2/app/templates/components/stats-card.hbs rename to ui-v2/app/components/stats-card/index.hbs diff --git a/ui-v2/app/components/stats-card.js b/ui-v2/app/components/stats-card/index.js similarity index 100% rename from ui-v2/app/components/stats-card.js rename to ui-v2/app/components/stats-card/index.js diff --git a/ui-v2/app/templates/components/tab-nav.hbs b/ui-v2/app/components/tab-nav/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tab-nav.hbs rename to ui-v2/app/components/tab-nav/index.hbs diff --git a/ui-v2/app/components/tab-nav.js b/ui-v2/app/components/tab-nav/index.js similarity index 100% rename from ui-v2/app/components/tab-nav.js rename to ui-v2/app/components/tab-nav/index.js diff --git a/ui-v2/app/templates/components/tab-section.hbs b/ui-v2/app/components/tab-section/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tab-section.hbs rename to ui-v2/app/components/tab-section/index.hbs diff --git a/ui-v2/app/components/tab-section.js b/ui-v2/app/components/tab-section/index.js similarity index 100% rename from ui-v2/app/components/tab-section.js rename to ui-v2/app/components/tab-section/index.js diff --git a/ui-v2/app/templates/components/tabular-collection.hbs b/ui-v2/app/components/tabular-collection/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tabular-collection.hbs rename to ui-v2/app/components/tabular-collection/index.hbs diff --git a/ui-v2/app/components/tabular-collection.js b/ui-v2/app/components/tabular-collection/index.js similarity index 100% rename from ui-v2/app/components/tabular-collection.js rename to ui-v2/app/components/tabular-collection/index.js diff --git a/ui-v2/app/templates/components/tabular-details.hbs b/ui-v2/app/components/tabular-details/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tabular-details.hbs rename to ui-v2/app/components/tabular-details/index.hbs diff --git a/ui-v2/app/components/tabular-details.js b/ui-v2/app/components/tabular-details/index.js similarity index 100% rename from ui-v2/app/components/tabular-details.js rename to ui-v2/app/components/tabular-details/index.js diff --git a/ui-v2/app/templates/components/tag-list.hbs b/ui-v2/app/components/tag-list/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tag-list.hbs rename to ui-v2/app/components/tag-list/index.hbs diff --git a/ui-v2/app/components/tag-list.js b/ui-v2/app/components/tag-list/index.js similarity index 100% rename from ui-v2/app/components/tag-list.js rename to ui-v2/app/components/tag-list/index.js diff --git a/ui-v2/app/templates/components/templated-anchor.hbs b/ui-v2/app/components/templated-anchor/index.hbs similarity index 100% rename from ui-v2/app/templates/components/templated-anchor.hbs rename to ui-v2/app/components/templated-anchor/index.hbs diff --git a/ui-v2/app/components/templated-anchor.js b/ui-v2/app/components/templated-anchor/index.js similarity index 100% rename from ui-v2/app/components/templated-anchor.js rename to ui-v2/app/components/templated-anchor/index.js diff --git a/ui-v2/app/templates/components/toggle-button.hbs b/ui-v2/app/components/toggle-button/index.hbs similarity index 100% rename from ui-v2/app/templates/components/toggle-button.hbs rename to ui-v2/app/components/toggle-button/index.hbs diff --git a/ui-v2/app/components/toggle-button.js b/ui-v2/app/components/toggle-button/index.js similarity index 100% rename from ui-v2/app/components/toggle-button.js rename to ui-v2/app/components/toggle-button/index.js diff --git a/ui-v2/app/templates/components/token-list.hbs b/ui-v2/app/components/token-list/index.hbs similarity index 74% rename from ui-v2/app/templates/components/token-list.hbs rename to ui-v2/app/components/token-list/index.hbs index add5e8aa1..8b7dc9df3 100644 --- a/ui-v2/app/templates/components/token-list.hbs +++ b/ui-v2/app/components/token-list/index.hbs @@ -1,11 +1,11 @@ {{yield}} {{#if (gt items.length 0)}} - {{#tabular-collection + {{#if caption}} {{caption}} {{/if}} @@ -15,7 +15,7 @@ Description - + {{truncate item.AccessorID 8 false}} @@ -25,5 +25,5 @@

{{item.Description}}

- {{/tabular-collection}} +
{{/if}} \ No newline at end of file diff --git a/ui-v2/app/components/token-list.js b/ui-v2/app/components/token-list/index.js similarity index 100% rename from ui-v2/app/components/token-list.js rename to ui-v2/app/components/token-list/index.js diff --git a/ui-v2/app/templates/components/tomography-graph.hbs b/ui-v2/app/components/tomography-graph/index.hbs similarity index 100% rename from ui-v2/app/templates/components/tomography-graph.hbs rename to ui-v2/app/components/tomography-graph/index.hbs diff --git a/ui-v2/app/components/tomography-graph.js b/ui-v2/app/components/tomography-graph/index.js similarity index 100% rename from ui-v2/app/components/tomography-graph.js rename to ui-v2/app/components/tomography-graph/index.js diff --git a/ui-v2/app/templates/dc/acls/policies/-form.hbs b/ui-v2/app/templates/dc/acls/policies/-form.hbs index a2d60570b..0ab52245d 100644 --- a/ui-v2/app/templates/dc/acls/policies/-form.hbs +++ b/ui-v2/app/templates/dc/acls/policies/-form.hbs @@ -21,7 +21,10 @@ {{#if (gt items.length 0)}} - {{#modal-dialog data-test-delete-modal onclose=(action cancel)}} +

Policy in Use

@@ -38,7 +41,7 @@
- {{/modal-dialog}} + {{else}} {{/if}} diff --git a/ui-v2/app/templates/dc/nodes/metadata.hbs b/ui-v2/app/templates/dc/nodes/-metadata.hbs similarity index 80% rename from ui-v2/app/templates/dc/nodes/metadata.hbs rename to ui-v2/app/templates/dc/nodes/-metadata.hbs index 1f7680249..bd1936d99 100644 --- a/ui-v2/app/templates/dc/nodes/metadata.hbs +++ b/ui-v2/app/templates/dc/nodes/-metadata.hbs @@ -1,9 +1,9 @@ {{#if item.Meta}} {{#with (object-entries item.Meta) as |meta|}} - {{#tabular-collection - data-test-metadata - items=meta as |item index| - }} + Key Value @@ -18,7 +18,7 @@ {{object-at 1 item}} - {{/tabular-collection}} + {{/with}} {{else}}

diff --git a/ui-v2/app/templates/dc/nodes/-services.hbs b/ui-v2/app/templates/dc/nodes/-services.hbs index 83a2caaae..420e45b3c 100644 --- a/ui-v2/app/templates/dc/nodes/-services.hbs +++ b/ui-v2/app/templates/dc/nodes/-services.hbs @@ -6,36 +6,36 @@ {{/if}} - {{#tabular-collection + - Service - Port - Tags - - - - - {{#let (service/external-source item) as |externalSource| }} - {{#if externalSource }} - - {{else}} - - {{/if}} - {{/let}} - {{item.Service}}{{#if (not-eq item.ID item.Service) }} ({{item.ID}}){{/if}} - - - - {{item.Port}} - - - - - - {{/tabular-collection}} + @items={{filtered}} as |item index| + > + + Service + Port + Tags + + + + + {{#let (service/external-source item) as |externalSource| }} + {{#if externalSource }} + + {{else}} + + {{/if}} + {{/let}} + {{item.Service}}{{#if (not-eq item.ID item.Service) }} ({{item.ID}}){{/if}} + + + + {{item.Port}} + + + + + +

diff --git a/ui-v2/app/templates/dc/nodes/-sessions.hbs b/ui-v2/app/templates/dc/nodes/-sessions.hbs index e34e6c8d4..8bc240c3a 100644 --- a/ui-v2/app/templates/dc/nodes/-sessions.hbs +++ b/ui-v2/app/templates/dc/nodes/-sessions.hbs @@ -1,9 +1,9 @@ {{#if (gt sessions.length 0)}} - {{#tabular-collection - data-test-sessions - class="sessions" - items=sessions as |item index| - }} + Name ID @@ -49,7 +49,7 @@ - {{/tabular-collection}} + {{else}}

There are no Lock Sessions for this Node. For more information, view our documentation diff --git a/ui-v2/app/templates/dc/services/-addresses.hbs b/ui-v2/app/templates/dc/services/-addresses.hbs index 5df6852fe..4ba07aed3 100644 --- a/ui-v2/app/templates/dc/services/-addresses.hbs +++ b/ui-v2/app/templates/dc/services/-addresses.hbs @@ -1,23 +1,23 @@ {{#if item.TaggedAddresses }} -{{#tabular-collection + - Tag - Address - - -{{#with (object-at 1 taggedAddress) as |address|}} - - {{object-at 0 taggedAddress}}{{#if (and (eq address.Address item.Address) (eq address.Port item.Port))}} (default){{/if}} - - - {{address.Address}}:{{address.Port}} - -{{/with}} - -{{/tabular-collection}} + @items={{object-entries item.TaggedAddresses}} as |taggedAddress index| + > + + Tag + Address + + + {{#with (object-at 1 taggedAddress) as |address|}} + + {{object-at 0 taggedAddress}}{{#if (and (eq address.Address item.Address) (eq address.Port item.Port))}} (default){{/if}} + + + {{address.Address}}:{{address.Port}} + + {{/with}} + + {{else}}

There are no additional addresses. diff --git a/ui-v2/app/templates/dc/services/-exposedpaths.hbs b/ui-v2/app/templates/dc/services/-exposedpaths.hbs index 3fba75fb8..7222f7a81 100644 --- a/ui-v2/app/templates/dc/services/-exposedpaths.hbs +++ b/ui-v2/app/templates/dc/services/-exposedpaths.hbs @@ -1,11 +1,11 @@

You can expose individual HTTP paths like /metrics through Envoy for external services like Prometheus.

-{{#tabular-collection - data-test-exposedpaths - class="exposedpaths" - items=item.Proxy.Expose.Paths as |path index| -}} + Path Protocol @@ -30,4 +30,4 @@ {{item.Address}}:{{path.ListenerPort}}{{path.Path}} -{{/tabular-collection}} + diff --git a/ui-v2/app/templates/dc/services/-instances.hbs b/ui-v2/app/templates/dc/services/-instances.hbs index b317a8987..11de5220e 100644 --- a/ui-v2/app/templates/dc/services/-instances.hbs +++ b/ui-v2/app/templates/dc/services/-instances.hbs @@ -6,10 +6,10 @@ {{/if}} - {{#tabular-collection - data-test-instances - items=filtered as |item index| - }} + ID Node @@ -47,7 +47,7 @@ {{/with}} - {{/tabular-collection}} +

diff --git a/ui-v2/app/templates/dc/services/metadata.hbs b/ui-v2/app/templates/dc/services/-metadata.hbs similarity index 80% rename from ui-v2/app/templates/dc/services/metadata.hbs rename to ui-v2/app/templates/dc/services/-metadata.hbs index e1fb12657..e1061be4c 100644 --- a/ui-v2/app/templates/dc/services/metadata.hbs +++ b/ui-v2/app/templates/dc/services/-metadata.hbs @@ -1,9 +1,9 @@ {{#if item.Meta}} {{#with (object-entries item.Meta) as |meta|}} - {{#tabular-collection - data-test-metadata - items=meta as |item index| - }} + Key Value @@ -18,7 +18,7 @@ {{object-at 1 item}} - {{/tabular-collection}} + {{/with}} {{else}}

diff --git a/ui-v2/app/templates/dc/services/-upstreams.hbs b/ui-v2/app/templates/dc/services/-upstreams.hbs index a1cb0f474..af051a0d6 100644 --- a/ui-v2/app/templates/dc/services/-upstreams.hbs +++ b/ui-v2/app/templates/dc/services/-upstreams.hbs @@ -1,8 +1,8 @@ {{#if (gt item.Proxy.Upstreams.length 0) }} -{{#tabular-collection - data-test-upstreams - items=item.Proxy.Upstreams as |item index| -}} + Upstream Datacenter @@ -31,7 +31,7 @@ {{item.LocalBindAddress}}:{{item.LocalBindPort}} -{{/tabular-collection}} + {{else}}

There are no upstreams. diff --git a/ui-v2/tests/steps/assertions/model.js b/ui-v2/tests/steps/assertions/model.js index 12f6b2ae9..a42066f1c 100644 --- a/ui-v2/tests/steps/assertions/model.js +++ b/ui-v2/tests/steps/assertions/model.js @@ -15,7 +15,6 @@ export default function(scenario, assert, find, currentPage, pauseUntil, plurali const len = currentPage()[pluralize(model)].filter(function(item) { return item.isVisible; }).length; - assert.equal(len, num, `Expected ${num} ${pluralize(model)}, saw ${len}`); }) .then(['I see $num $model model[s]? on the $component component'], function(