2

I have an option list using bootstrap-vue as shown:

enter image description here

It looks fine in the selection window, but when opening the drop-down not all icons show. Once the icon is selected, it shows:

enter image description here

I.e. bolt is showing [], but when selected:

enter image description here

Code for Icon column:

<template v-slot:cell(icon)="row">
    <b-form-select v-model="row.item.icon" class="fa">
        <b-form-select-option value="anchor"> &#xf13d; anchor</b-form-select-option>
        <b-form-select-option value="angle-double-up"> &#xf102; angle-double-up</b-form-select-option>
        <b-form-select-option value="angle-double-down"> &#xf103; angle-double-down</b-form-select-option>
        <b-form-select-option value="angle-double-left"> &#xf100; angle-double-left</b-form-select-option>
        <b-form-select-option value="angle-double-right"> &#xf101; angle-double-right</b-form-select-option>
        <b-form-select-option value="angle-up"> &#xf106; angle-up</b-form-select-option>
        <b-form-select-option value="angle-down"> &#xf107; angle-down</b-form-select-option>
        <b-form-select-option value="angle-left"> &#xf104; angle-left</b-form-select-option>
        <b-form-select-option value="angle-right"> &#xf105; angle-right</b-form-select-option>
        <b-form-select-option value="archive"> &#xf187; archive</b-form-select-option>
        <b-form-select-option value="asterisk"> &#xf069; asterisk</b-form-select-option>
        <b-form-select-option value="at"> &#xf1fa; at</b-form-select-option>
        <b-form-select-option value="automobile"> &#xf1b9; automobile</b-form-select-option>
        <b-form-select-option value="balance-scale"> &#xf24e; balance-scale</b-form-select-option>
        <b-form-select-option value="ban"> &#xf05e; ban</b-form-select-option>
        <b-form-select-option value="bank"> &#xf19c; bank</b-form-select-option>
        <b-form-select-option value="bar-chart"> &#xf080; bar-chart</b-form-select-option>
        <b-form-select-option value="barcode"> &#xf02a; barcode</b-form-select-option>
        <b-form-select-option value="battery-full"> &#xf240; battery-full</b-form-select-option>
        <b-form-select-option value="bell"> &#xf0f3; bell</b-form-select-option>
        <b-form-select-option value="binoculars"> &#xf1e5; binoculars</b-form-select-option>
        <b-form-select-option value="bolt"> &#xf0e7; bolt</b-form-select-option>
        <b-form-select-option value="book"> &#xf02d; book</b-form-select-option>
        <b-form-select-option value="bookmark"> &#xf02e; bookmark</b-form-select-option>
        <b-form-select-option value="briefcase"> &#xf0b1; briefcase</b-form-select-option>
        <b-form-select-option value="building"> &#xf1ad; building</b-form-select-option>
        <b-form-select-option value="calculator"> &#xf1ec; calculator</b-form-select-option>
        <b-form-select-option value="bullseye"> &#xf140; bullseye</b-form-select-option>
        <b-form-select-option value="bullhorn"> &#xf0a1; bullhorn</b-form-select-option>
        <b-form-select-option value="calendar"> &#xf073; calendar</b-form-select-option>
        <b-form-select-option value="camera-retro"> &#xf083; camera-retro</b-form-select-option>
        <b-form-select-option value="car"> &#xf1b9; car</b-form-select-option>
        <b-form-select-option value="certificate"> &#xf0a3; certificate</b-form-select-option>
        <b-form-select-option value="chain"> &#xf0c1; chain</b-form-select-option>
        <b-form-select-option value="chain-broken"> &#xf127; chain-broken</b-form-select-option>
        <b-form-select-option value="check"> &#xf00c; check</b-form-select-option>
        <b-form-select-option value="child"> &#xf1ae; child</b-form-select-option>
        <b-form-select-option value="cog"> &#xf013; cog</b-form-select-option>
        <b-form-select-option value="cogs"> &#xf085; cogs</b-form-select-option>
        <b-form-select-option value="ship"> &#xf21a; ship</b-form-select-option>
    </b-form-select>
</template>

Very odd.. ideas?

EDIT 1: I have noticed it is consistently the same icons which will show. Also, bookmark icon is outline in option list, but solid when selected...

enter image description here

Ajility
  • 526
  • 3
  • 19

1 Answers1

1

Further searching helped me stumble upon this answer by @Behrang Saeedzadeh https://stackoverflow.com/a/22598619/5449796

I was using:

    <b-form-select v-model="row.item.icon" class="fa">
        <b-form-select-option value="anchor"> &#xf13d; anchor</b-form-select-option>

I should have used:

    <b-form-select v-model="row.item.icon" class="fa">
        <b-form-select-option class="fa" value="anchor"> &#xf13d; anchor</b-form-select-option>

As for some icons showing in the list, I don't know why that happened.

It makes sense that the icon showed when it was selected though, since class="fa" was on the parent.

Ajility
  • 526
  • 3
  • 19