Switch to new slot syntax

This commit is contained in:
Pig Fang 2019-03-30 14:39:55 +08:00
parent 9989291941
commit e49c40cc08
8 changed files with 20 additions and 16 deletions

View File

@ -7,7 +7,7 @@
:pagination-options="tableOptions.pagination"
style-class="vgt-table striped"
>
<template slot="table-row" slot-scope="props">
<template #table-row="props">
<span v-if="props.column.field === 'title'">
<strong>{{ props.formattedRow[props.column.field] }}</strong>
<div>{{ props.row.name }}</div>

View File

@ -13,7 +13,7 @@
@on-search="onSearch"
@on-per-page-change="onPerPageChange"
>
<template slot="table-row" slot-scope="props">
<template #table-row="props">
<span v-if="props.column.field === 'name'">
{{ props.formattedRow[props.column.field] }}
<a :title="$t('admin.changePlayerName')" data-test="name" @click="changeName(props.row)">

View File

@ -8,7 +8,7 @@
style-class="vgt-table striped"
:row-style-class="rowStyleClassFn"
>
<template slot="table-row" slot-scope="props">
<template #table-row="props">
<span v-if="props.column.field === 'title'">
<strong>{{ props.formattedRow[props.column.field] }}</strong>
<div v-if="props.row.enabled" class="actions">

View File

@ -13,7 +13,7 @@
@on-search="onSearch"
@on-per-page-change="onPerPageChange"
>
<template slot="table-row" slot-scope="props">
<template #table-row="props">
<span v-if="props.column.field === 'email'">
{{ props.formattedRow[props.column.field] }}
<a :title="$t('admin.changeEmail')" data-test="email" @click="changeEmail(props.row)">

View File

@ -29,15 +29,19 @@
:placeholder="$t('vendor.datatable.search')"
clearable
>
<el-select slot="prepend" v-model="filter" class="texture-type-select">
<el-option :label="$t('general.skin')" value="skin" />
<el-option label="Steve" value="steve" />
<el-option label="Alex" value="alex" />
<el-option :label="$t('general.cape')" value="cape" />
</el-select>
<el-button slot="append" data-test="btn-search" @click="fetchData">
{{ $t('general.submit') }}
</el-button>
<template #prepend>
<el-select v-model="filter" class="texture-type-select">
<el-option :label="$t('general.skin')" value="skin" />
<el-option label="Steve" value="steve" />
<el-option label="Alex" value="alex" />
<el-option :label="$t('general.cape')" value="cape" />
</el-select>
</template>
<template #append>
<el-button data-test="btn-search" @click="fetchData">
{{ $t('general.submit') }}
</el-button>
</template>
</el-input>
</form>

View File

@ -6,7 +6,7 @@
:cape="type === 'cape' ? textureUrl : ''"
:init-position-z="60"
>
<template slot="footer">
<template #footer>
<el-button v-if="!auth" disabled :title="$t('skinlib.show.anonymous')">
{{ $t('skinlib.addToCloset') }}
</el-button>

View File

@ -126,7 +126,7 @@
<!-- Right col -->
<div class="col-md-4">
<previewer closet-mode :skin="skinUrl" :cape="capeUrl">
<template slot="footer">
<template #footer>
<button
v-t="'user.useAs'"
class="btn btn-primary"

View File

@ -69,7 +69,7 @@
:cape="capeUrl"
title="user.player.player-info"
>
<template slot="footer">
<template #footer>
<button
v-t="'user.switch2dPreview'"
class="btn btn-default"