Commit a1c864d1 authored by Sarah Groff Hennigh-Palermo's avatar Sarah Groff Hennigh-Palermo Committed by Phil Hughes

Fix two bugs in environments table

parent 0ab35262
...@@ -6,6 +6,7 @@ import _ from 'underscore'; ...@@ -6,6 +6,7 @@ import _ from 'underscore';
import { GlTooltipDirective } from '@gitlab/ui'; import { GlTooltipDirective } from '@gitlab/ui';
import UserAvatarLink from '~/vue_shared/components/user_avatar/user_avatar_link.vue'; import UserAvatarLink from '~/vue_shared/components/user_avatar/user_avatar_link.vue';
import Icon from '~/vue_shared/components/icon.vue'; import Icon from '~/vue_shared/components/icon.vue';
import TooltipOnTruncate from '~/vue_shared/components/tooltip_on_truncate.vue';
import environmentItemMixin from 'ee_else_ce/environments/mixins/environment_item_mixin'; import environmentItemMixin from 'ee_else_ce/environments/mixins/environment_item_mixin';
import ActionsComponent from './environment_actions.vue'; import ActionsComponent from './environment_actions.vue';
import ExternalUrlComponent from './environment_external_url.vue'; import ExternalUrlComponent from './environment_external_url.vue';
...@@ -26,7 +27,6 @@ const timeagoInstance = new Timeago(); ...@@ -26,7 +27,6 @@ const timeagoInstance = new Timeago();
export default { export default {
components: { components: {
UserAvatarLink,
CommitComponent, CommitComponent,
Icon, Icon,
ActionsComponent, ActionsComponent,
...@@ -35,6 +35,8 @@ export default { ...@@ -35,6 +35,8 @@ export default {
RollbackComponent, RollbackComponent,
TerminalButtonComponent, TerminalButtonComponent,
MonitoringButtonComponent, MonitoringButtonComponent,
TooltipOnTruncate,
UserAvatarLink,
}, },
directives: { directives: {
GlTooltip: GlTooltipDirective, GlTooltip: GlTooltipDirective,
...@@ -508,12 +510,16 @@ export default { ...@@ -508,12 +510,16 @@ export default {
</div> </div>
<div class="table-section section-15 d-none d-sm-none d-md-block" role="gridcell"> <div class="table-section section-15 d-none d-sm-none d-md-block" role="gridcell">
<a <a v-if="shouldRenderBuildName" :href="buildPath" class="build-link cgray">
v-if="shouldRenderBuildName" <tooltip-on-truncate
:href="buildPath" :title="buildName"
class="build-link cgray flex-truncate-parent" truncate-target="child"
> class="flex-truncate-parent"
<span class="flex-truncate-child">{{ buildName }}</span> >
<span class="flex-truncate-child">
{{ buildName }}
</span>
</tooltip-on-truncate>
</a> </a>
</div> </div>
......
...@@ -31,10 +31,6 @@ export default { ...@@ -31,10 +31,6 @@ export default {
type: Boolean, type: Boolean,
required: true, required: true,
}, },
cssContainerClass: {
type: String,
required: true,
},
newEnvironmentPath: { newEnvironmentPath: {
type: String, type: String,
required: true, required: true,
...@@ -93,7 +89,7 @@ export default { ...@@ -93,7 +89,7 @@ export default {
}; };
</script> </script>
<template> <template>
<div :class="cssContainerClass"> <div>
<stop-environment-modal :environment="environmentInStopModal" /> <stop-environment-modal :environment="environmentInStopModal" />
<confirm-rollback-modal :environment="environmentInRollbackModal" /> <confirm-rollback-modal :environment="environmentInRollbackModal" />
......
...@@ -21,7 +21,6 @@ export default () => ...@@ -21,7 +21,6 @@ export default () =>
newEnvironmentPath: environmentsData.newEnvironmentPath, newEnvironmentPath: environmentsData.newEnvironmentPath,
helpPagePath: environmentsData.helpPagePath, helpPagePath: environmentsData.helpPagePath,
deployBoardsHelpPath: environmentsData.deployBoardsHelpPath, deployBoardsHelpPath: environmentsData.deployBoardsHelpPath,
cssContainerClass: environmentsData.cssClass,
canCreateEnvironment: parseBoolean(environmentsData.canCreateEnvironment), canCreateEnvironment: parseBoolean(environmentsData.canCreateEnvironment),
canReadEnvironment: parseBoolean(environmentsData.canReadEnvironment), canReadEnvironment: parseBoolean(environmentsData.canReadEnvironment),
}; };
...@@ -33,7 +32,6 @@ export default () => ...@@ -33,7 +32,6 @@ export default () =>
newEnvironmentPath: this.newEnvironmentPath, newEnvironmentPath: this.newEnvironmentPath,
helpPagePath: this.helpPagePath, helpPagePath: this.helpPagePath,
deployBoardsHelpPath: this.deployBoardsHelpPath, deployBoardsHelpPath: this.deployBoardsHelpPath,
cssContainerClass: this.cssContainerClass,
canCreateEnvironment: this.canCreateEnvironment, canCreateEnvironment: this.canCreateEnvironment,
canReadEnvironment: this.canReadEnvironment, canReadEnvironment: this.canReadEnvironment,
...this.canaryCalloutProps, ...this.canaryCalloutProps,
......
---
title: Fix tooltip hovers in environments table
merge_request: 20737
author:
type: fixed
...@@ -10,7 +10,6 @@ describe('Environment', () => { ...@@ -10,7 +10,6 @@ describe('Environment', () => {
endpoint: 'environments.json', endpoint: 'environments.json',
canCreateEnvironment: true, canCreateEnvironment: true,
canReadEnvironment: true, canReadEnvironment: true,
cssContainerClass: 'container',
newEnvironmentPath: 'environments/new', newEnvironmentPath: 'environments/new',
helpPagePath: 'help', helpPagePath: 'help',
canaryDeploymentFeatureId: 'canary_deployment', canaryDeploymentFeatureId: 'canary_deployment',
......
...@@ -10,7 +10,6 @@ describe('Environment', () => { ...@@ -10,7 +10,6 @@ describe('Environment', () => {
endpoint: 'environments.json', endpoint: 'environments.json',
canCreateEnvironment: true, canCreateEnvironment: true,
canReadEnvironment: true, canReadEnvironment: true,
cssContainerClass: 'container',
newEnvironmentPath: 'environments/new', newEnvironmentPath: 'environments/new',
helpPagePath: 'help', helpPagePath: 'help',
canaryDeploymentFeatureId: 'canary_deployment', canaryDeploymentFeatureId: 'canary_deployment',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment