diff --git a/ui-v2/app/components/empty-state/index.hbs b/ui-v2/app/components/empty-state/index.hbs index 8af5c27163..c4c255826b 100644 --- a/ui-v2/app/components/empty-state/index.hbs +++ b/ui-v2/app/components/empty-state/index.hbs @@ -1,5 +1,6 @@ {{yield}}
+{{#if hasHeader}}
{{#yield-slot name="header"}} {{yield}} @@ -8,6 +9,7 @@ {{yield}} {{/yield-slot}}
+{{/if}} {{#yield-slot name="body"}}
{{yield}} diff --git a/ui-v2/app/components/empty-state/index.js b/ui-v2/app/components/empty-state/index.js index a7be4db131..2a0182c368 100644 --- a/ui-v2/app/components/empty-state/index.js +++ b/ui-v2/app/components/empty-state/index.js @@ -1,6 +1,11 @@ import Component from '@ember/component'; +import { set } from '@ember/object'; import Slotted from 'block-slots'; export default Component.extend(Slotted, { tagName: '', + willRender: function() { + this._super(...arguments); + set(this, 'hasHeader', this._isRegistered('header') || this._isRegistered('subheader')); + }, }); diff --git a/ui-v2/app/styles/components/empty-state/layout.scss b/ui-v2/app/styles/components/empty-state/layout.scss index f2baee0dd7..4de69fe593 100644 --- a/ui-v2/app/styles/components/empty-state/layout.scss +++ b/ui-v2/app/styles/components/empty-state/layout.scss @@ -40,3 +40,7 @@ %empty-state-anchor::before { margin-top: -1px; } +%empty-state > div:only-child { + padding: 50px 0 10px 0; + text-align: center; +} diff --git a/ui-v2/app/styles/core/typography.scss b/ui-v2/app/styles/core/typography.scss index 949b2b52de..d6e7724bcf 100644 --- a/ui-v2/app/styles/core/typography.scss +++ b/ui-v2/app/styles/core/typography.scss @@ -42,7 +42,7 @@ pre code, %flash-message p, %filter-bar input, %phrase-editor input, -%tab-section section p { +%tab-section p { @extend %p1; } %menu-panel dl, @@ -60,6 +60,7 @@ pre code, } .template-error > div, %empty-state-subheader, +%empty-state p, %button, %main-content p, %form-element-note, diff --git a/ui-v2/app/templates/dc/nodes/show/healthchecks.hbs b/ui-v2/app/templates/dc/nodes/show/healthchecks.hbs index 06836132e7..2bbf0747b2 100644 --- a/ui-v2/app/templates/dc/nodes/show/healthchecks.hbs +++ b/ui-v2/app/templates/dc/nodes/show/healthchecks.hbs @@ -3,9 +3,13 @@ {{#if (gt item.Checks.length 0) }} {{else}} -

- This node has no health checks. -

+ + +

+ This node has no health checks. +

+
+
{{/if}}
\ No newline at end of file diff --git a/ui-v2/app/templates/dc/nodes/show/metadata.hbs b/ui-v2/app/templates/dc/nodes/show/metadata.hbs index a7c0308f34..5f985d9e43 100644 --- a/ui-v2/app/templates/dc/nodes/show/metadata.hbs +++ b/ui-v2/app/templates/dc/nodes/show/metadata.hbs @@ -3,9 +3,13 @@ {{#if item.Meta}} {{else}} -

- This node has no metadata. -

+ + +

+ This node has no metadata. +

+
+
{{/if}} diff --git a/ui-v2/app/templates/dc/nodes/show/services.hbs b/ui-v2/app/templates/dc/nodes/show/services.hbs index ab07361250..f885ca2933 100644 --- a/ui-v2/app/templates/dc/nodes/show/services.hbs +++ b/ui-v2/app/templates/dc/nodes/show/services.hbs @@ -13,9 +13,13 @@ -

- There are no services. -

+ + +

+ There are no services. +

+
+
diff --git a/ui-v2/app/templates/dc/nodes/show/sessions.hbs b/ui-v2/app/templates/dc/nodes/show/sessions.hbs index 30bf919f52..8b3a50d43b 100644 --- a/ui-v2/app/templates/dc/nodes/show/sessions.hbs +++ b/ui-v2/app/templates/dc/nodes/show/sessions.hbs @@ -53,9 +53,13 @@ {{else}} -

- There are no Lock Sessions for this Node. For more information, view our documentation -

+ + +

+ There are no Lock Sessions for this Node. For more information, view our documentation +

+
+
{{/if}} diff --git a/ui-v2/app/templates/dc/services/instance/metadata.hbs b/ui-v2/app/templates/dc/services/instance/metadata.hbs index 8ec4c816d3..7d19fd0801 100644 --- a/ui-v2/app/templates/dc/services/instance/metadata.hbs +++ b/ui-v2/app/templates/dc/services/instance/metadata.hbs @@ -5,9 +5,13 @@ {{#if (gt item.Tags.length 0) }} {{else}} -

- There are no tags. -

+ + +

+ There are no tags. +

+
+
{{/if}} diff --git a/ui-v2/app/templates/dc/services/instance/tags.hbs b/ui-v2/app/templates/dc/services/instance/tags.hbs deleted file mode 100644 index c0c620962e..0000000000 --- a/ui-v2/app/templates/dc/services/instance/tags.hbs +++ /dev/null @@ -1,11 +0,0 @@ -
-
- {{#if (gt item.Tags.length 0) }} - - {{else}} -

- There are no tags. -

- {{/if}} -
-
diff --git a/ui-v2/app/templates/dc/services/show/instances.hbs b/ui-v2/app/templates/dc/services/show/instances.hbs index 787547d2ea..5c5a4ca79b 100644 --- a/ui-v2/app/templates/dc/services/show/instances.hbs +++ b/ui-v2/app/templates/dc/services/show/instances.hbs @@ -12,9 +12,13 @@ -

- There are no services. -

+ + +

+ There are no services. +

+
+
diff --git a/ui-v2/app/templates/dc/services/show/intentions.hbs b/ui-v2/app/templates/dc/services/show/intentions.hbs index 19edd40a8f..279989d29c 100644 --- a/ui-v2/app/templates/dc/services/show/intentions.hbs +++ b/ui-v2/app/templates/dc/services/show/intentions.hbs @@ -34,9 +34,13 @@ /> -

- There are no intentions for this service. -

+ + +

+ There are no intentions for this service. +

+
+
diff --git a/ui-v2/app/templates/dc/services/show/services.hbs b/ui-v2/app/templates/dc/services/show/services.hbs index 8e27b88598..b42e7a30e3 100644 --- a/ui-v2/app/templates/dc/services/show/services.hbs +++ b/ui-v2/app/templates/dc/services/show/services.hbs @@ -1,17 +1,19 @@
{{#if (gt gatewayServices.length 0)}} -

The following services may receive traffic from external services through this gateway. Learn more about configuring gateways in our step-by-step guide.

-
{{else}} -

- There are no linked services. -

+ + +

+ There are no linked services. +

+
+
{{/if}}
diff --git a/ui-v2/app/templates/dc/services/show/tags.hbs b/ui-v2/app/templates/dc/services/show/tags.hbs index a3cb6a6e35..7184728017 100644 --- a/ui-v2/app/templates/dc/services/show/tags.hbs +++ b/ui-v2/app/templates/dc/services/show/tags.hbs @@ -3,9 +3,13 @@ {{#if (gt item.Tags.length 0) }} {{else}} -

- There are no tags. -

+ + +

+ There are no tags. +

+
+
{{/if}} diff --git a/ui-v2/app/templates/dc/services/show/upstreams.hbs b/ui-v2/app/templates/dc/services/show/upstreams.hbs index b4cac65e4e..d300097615 100644 --- a/ui-v2/app/templates/dc/services/show/upstreams.hbs +++ b/ui-v2/app/templates/dc/services/show/upstreams.hbs @@ -1,16 +1,18 @@
{{#if (gt gatewayServices.length 0)}} -

Upstreams are services that may receive traffic from this gateway. Learn more about configuring gateways in our documentation.

-
{{else}} -

- There are no upstreams. -

+ + +

+ There are no upstreams. +

+
+
{{/if}}