Skip to content

Commit 57f15e4

Browse files
committed
BlockLog.vue: remove 'Target' column from active blocks table
On this page, the target is always the same Bug: T383180 Change-Id: I1f014aec695092aa072495138a24dd44683e4aaf
1 parent f7695e7 commit 57f15e4

File tree

1 file changed

+9
-9
lines changed
  • resources/src/mediawiki.special.block/components

1 file changed

+9
-9
lines changed

resources/src/mediawiki.special.block/components/BlockLog.vue

+9-9
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,6 @@
6969
<template v-if="blockLogType !== 'active'" #item-type="{ item }">
7070
{{ util.getBlockActionMessage( item ) }}
7171
</template>
72-
<template v-if="blockLogType === 'active'" #item-target="{ item }">
73-
<!-- eslint-disable-next-line vue/no-v-html -->
74-
<span v-html="$i18n( 'userlink-with-contribs', item ).parse()"></span>
75-
</template>
7672
<template #item-expiry="{ item }">
7773
<span v-if="item.expires || item.duration">
7874
{{ util.formatTimestamp( item.expires || item.duration ) }}
@@ -150,15 +146,19 @@ module.exports = exports = defineComponent( {
150146
const columns = [
151147
...( props.blockLogType === 'active' || props.canDeleteLogEntry ?
152148
[ { id: props.blockLogType === 'active' ? 'modify' : 'hide', label: '', minWidth: '100px' } ] : [] ),
153-
{ id: 'timestamp', label: mw.message( 'blocklist-timestamp' ).text(), minWidth: '112px' },
154-
props.blockLogType === 'recent' || props.blockLogType === 'suppress' ?
155-
{ id: 'type', label: mw.message( 'blocklist-type-header' ).text(), minWidth: '112px' } :
156-
{ id: 'target', label: mw.message( 'blocklist-target' ).text(), minWidth: '200px' },
149+
{ id: 'timestamp', label: mw.message( 'blocklist-timestamp' ).text(), minWidth: '112px' }
150+
];
151+
if ( props.blockLogType === 'recent' || props.blockLogType === 'suppress' ) {
152+
columns.push(
153+
{ id: 'type', label: mw.message( 'blocklist-type-header' ).text(), minWidth: '112px' }
154+
);
155+
}
156+
columns.push(
157157
{ id: 'expiry', label: mw.message( 'blocklist-expiry' ).text(), minWidth: '112px' },
158158
{ id: 'blockedby', label: mw.message( 'blocklist-by' ).text(), minWidth: '200px' },
159159
{ id: 'parameters', label: mw.message( 'blocklist-params' ).text(), minWidth: '160px' },
160160
{ id: 'reason', label: mw.message( 'blocklist-reason' ).text(), minWidth: '160px' }
161-
];
161+
);
162162
163163
const logEntries = ref( [] );
164164
const moreBlocks = ref( false );

0 commit comments

Comments
 (0)