Commit fed11bcc authored by Lukas Eipert's avatar Lukas Eipert

Move GlIcon import from mixin to components

The vue_shared/mixins/related_issuable_mixin.js exposed a component
import to the mixin consumers. This is a bad pattern, as there is a
disconnect between templates of the components utilizing the mixin and
the components they import. This is moving the import to the actual
components.
parent 2cb69315
......@@ -2,7 +2,6 @@ import { isEmpty } from 'lodash';
import { sprintf, __ } from '~/locale';
import { formatDate } from '~/lib/utils/datetime_utility';
import tooltip from '~/vue_shared/directives/tooltip';
import icon from '~/vue_shared/components/icon.vue';
import timeagoMixin from '~/vue_shared/mixins/timeago';
const mixins = {
......@@ -100,9 +99,6 @@ const mixins = {
default: () => ({}),
},
},
components: {
icon,
},
directives: {
tooltip,
},
......
<script>
import { GlIcon } from '@gitlab/ui';
import { __, sprintf } from '~/locale';
import relatedIssuableMixin from '~/vue_shared/mixins/related_issuable_mixin';
export default {
name: 'IssueToken',
components: {
GlIcon,
},
mixins: [relatedIssuableMixin],
props: {
isCondensed: {
......@@ -78,7 +82,7 @@ export default {
'issuable-info': !isCondensed,
}"
>
<icon
<gl-icon
v-if="hasState"
v-tooltip
:class="iconClass"
......
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