mirror of https://github.com/rancher/dashboard.git
FIx feedback from review
This commit is contained in:
parent
ca5a02acc9
commit
a156beed09
|
|
@ -143,12 +143,13 @@ export default {
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
// Cluster list number of items shown is configurbale via user preference
|
// Cluster list number of items shown is configurbale via user preference
|
||||||
setClusterListHeight(a) {
|
setClusterListHeight(maxToShow) {
|
||||||
const el = this.$refs.clusterList;
|
const el = this.$refs.clusterList;
|
||||||
|
const max = Math.min(maxToShow, this.clusters.length);
|
||||||
|
|
||||||
if (el) {
|
if (el) {
|
||||||
const $el = $(el);
|
const $el = $(el);
|
||||||
const h = 34 * a;
|
const h = 34 * max;
|
||||||
|
|
||||||
$el.css('height', `${ h }px`);
|
$el.css('height', `${ h }px`);
|
||||||
}
|
}
|
||||||
|
|
@ -213,7 +214,7 @@ export default {
|
||||||
/>
|
/>
|
||||||
<i v-if="clusterFilter.length > 0" class="icon icon-close" @click="clusterFilter=''" />
|
<i v-if="clusterFilter.length > 0" class="icon icon-close" @click="clusterFilter=''" />
|
||||||
</div>
|
</div>
|
||||||
<div ref="clusterList" class="clusters" :class="{'fixed-height': showClusterSearch}">
|
<div ref="clusterList" class="clusters">
|
||||||
<div v-for="c in clusters" :key="c.id" @click="hide()">
|
<div v-for="c in clusters" :key="c.id" @click="hide()">
|
||||||
<nuxt-link
|
<nuxt-link
|
||||||
v-if="c.ready"
|
v-if="c.ready"
|
||||||
|
|
@ -543,10 +544,6 @@ export default {
|
||||||
.clusters {
|
.clusters {
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
|
|
||||||
&.fixed-height {
|
|
||||||
height: $option-height * 4;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.none-matching {
|
.none-matching {
|
||||||
|
|
|
||||||
|
|
@ -183,8 +183,7 @@ export default {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<hr />
|
<div class="row mt-20">
|
||||||
<div class="row">
|
|
||||||
<div class="col span-4">
|
<div class="col span-4">
|
||||||
<LabeledSelect
|
<LabeledSelect
|
||||||
v-model.number="menuMaxClusters"
|
v-model.number="menuMaxClusters"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue