LoginSignup
5
1

More than 1 year has passed since last update.

Bootstrapと Fontawesome で綺麗なLINEアイコンを作る

Last updated at Posted at 2021-12-19

プロローグ

アプリ版Noteのフローティングアイコンの様に,綺麗なLINEアイコンを作りたい!
と思った場合,Twiterアイコンのようには単純には作れなかったので以下にソースコードを共有します.

完成イメージ

ちなみに完成図は以下,

スクリーンショット 2021-12-19 18.55.25.png

完成リンクは以下.

ソースコード

参考までに,Twitterアイコン用のソースコード量よりもLINEアイコン用ソースコードの方が多いことが見て取れます!

<div class="fixed-action-btn position-fixed bottom-0 start-0 " style="height: 65px; width: 185px;">
  <section class="text-center">
    <!-- twitter share -->
    <button class="btn btn-floating btn-dark btn-lg ripple-surface" style="min-width: 45px; background-color:#1DA1F2"
      type="button" onclick="share2Twitter()">
      <i class="fab fa-twitter fa-lg"></i>
    </button>
    <!-- line share -->
    <button class="btn btn-floating btn-dark btn-lg ripple-surface" style="min-width: 45px; background-color:#00B900"
      type="button" onclick="share2Line()">
      <i class="fas fa-circle fa-lg" style="color: #ffffff;"></i>
      <i class="fab fa-line fa-2x" style="color: #00B900;position:relative; top: -45px;"></i>
    </button>
    <!-- web share api-->
    <button class="btn btn-floating btn-light btn-lg ripple-surface" style="min-width: 45px; background-color:#ffffff"
      type="button" onclick="share()">
      <i class="fas fa-share-alt"></i>
    </button>
  </section>
  <!-- Menu button -->
</div>

おしまい

終わり

5
1
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
1