부트스트랩 : 4.5 버전
폰트어썸(아이콘) : 5.15.4 버전
부트 스크랩을 사용한 사이트 > 테이블 > 한 컬럼의 내용이 아이콘이어서 설명 추가함
$(function(){
$('[data-toggle="popover"]').popover({
trigger : 'hover'
,html : true
,content : '<i class=\"fab fa-youtube\"></i> : youtube / news.naver / tv.naver <br> '
+' <i class=\"fas fa-scroll\"></i> : terms.naver <br>'
+' <i class=\"fas fa-file\"></i> : .html <br>'
+' <i class=\"fas fa-minus\"></i> : 그 외 <br>'
})
});
<table>
<thead>
<tr>
<th>1</th>
<th>2</th>
<th style="text-align:center;" data-container="body" data-toggle="popover" data-placement="top" data-content="">
<i class="fas fa-question-circle"></i>
</th>
</tr>
</thead>
<tbody id="tempTable" >
...
</tbody>
</table>
[1. icon사용하기]
* 어떤 아이콘은 적용이 되고 어떤 건 오류는 안 나지만 영역이 0*0 으로 아이콘이 보이지 않는다
-> 유료버전은 사용할 수 없고 무료(fas와 fab) 버전을 써야 한다.
* 버전도 확인해야 함 버전에 따라 코드가 다름
https://fontawesome.com/v5/icons/question-circle?s=solid&f=classic
Font Awesome
The world’s most popular and easiest to use icon set just got an upgrade. More icons. More styles. More Options.
fontawesome.com
https://velog.io/@remon/Font-Awesome-Error-fas-fa-solid
Font Awesome Error!! (fas? fa-solid?)
검색바 만들기를 진행하던 중 👾에러가 생겼다ㅎ완성해야 될 화면.. 3가지의 아이콘이 필요했다. 근데 폰트어썸 아이콘이 안나온다..
velog.io
[2.popover]
* 작동을 안해서 버전확인해보니 내가 최신문서 버전보고 따라해서 적용이 안된 거 였음.
https://getbootstrap.com/docs/4.0/components/popovers/
popover 내용에 html넣기
https://www.tutorialrepublic.com/faq/how-to-insert-image-inside-bootstrap-popover.php
How to Insert Image inside Bootstrap Popover
How to insert image inside Bootstrap popover Topic: Bootstrap / SassPrev|Next Answer: Use the Popover's content Option You can pass the content option to the Bootstrap .popover() method to insert the images inside the popovers. You can also set this op
www.tutorialrepublic.com
https://fightingsean.tistory.com/47
Bootstrap popover content 에 table 넣기
bootstrap 4 에서 popover 에 table 콘텐츠 넣을면 적용이 되지 않는다. 이럴때 아래와 같이 설정 후 popover 를 적용하면 정상적으로 table 콘텐츠가 보여진다. $.fn.popover.Constructor.Default.whiteList.tab..
fightingsean.tistory.com
https://www.codingfactory.net/11670
Bootstrap 4 / Popovers / 클릭했을 때 메시지 나오게 하기
Popovers Popover를 이용하여 요소를 클릭했을 때 메시지가 있는 작은 창을 띄울 수 있습니다. 아래는 예제 실행 영상입니다. 예제 1 요소에 다음과 같은 속성을 추가합니다. data-toggle='popover' title='Popo
www.codingfactory.net
'차근차근 > 부트스트랩' 카테고리의 다른 글
부트스트랩 5.1 폰트 바꾸기 (0) | 2023.02.02 |
---|---|
가끔 404 (0) | 2022.11.15 |
부트스트랩 필요한 링크 (0) | 2022.08.11 |
메뉴 토글 -collapse2 (0) | 2022.03.23 |
메뉴 토글 -collapse (0) | 2022.03.22 |