2017-10-20 7 views
0

最初の画像リンクが私の必要条件です。グリッドに表示しないでください。だから私はCSSを使用してフィールドをぼかしている enter image description here 2番目の画像のリンクです。 CTRL + Aを選択するか、マウスから値を選択すると、ぼやけたフィールドが表示されます。 enter image description hereグリッドからグリッド値を選択すると、ぼやけた値が表示される

助けてください!

+1

あなたが唯一の唯一のクライアント側のコードでこれらの値を難読化はありますか?あなたがいれば、それはあなたが持つ一つの問題です。 – Haem

答えて

1

user-select: nonetd要素に設定して、それらが選択されないようにすることができます。

user-selectは、-webkit-mozという接頭辞が必要です。

const app = new Vue({ 
 
    el: "#app", 
 
    data: { 
 
    items: [{ 
 
     col1: "123", 
 
     col2: "456" 
 
    },{ 
 
     col1: "789", 
 
     col2: "012" 
 
    }] 
 
    } 
 
});
.no-select { 
 
    user-select: none; 
 
    -webkit-user-select: none; 
 
    -moz-user-select: none; 
 
} 
 

 
.blur { 
 
    filter: blur(3px); 
 
}
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.5.2/vue.min.js"></script> 
 
<div id="app"> 
 
    <table> 
 
    <thead> 
 
     <tr> 
 
     <th>Col1</th> 
 
     <th>Col2 (with no-select)</th> 
 
     <th>Col2 (without no-select)</th> 
 
     </tr> 
 
    </thead> 
 
    <tbody> 
 
     <tr v-for="item in items"> 
 
     <td>{{ item.col1 }}</td> 
 
     <td class="no-select blur">{{ item.col2 }}</td> 
 
     <td class=" blur">{{ item.col2 }}</td> 
 
     </tr> 
 
    </tbody> 
 
    </table> 
 
</div>

関連する問題