deprecated
2 months ago
block.json
3 months ago
component.js
3 months ago
edit.js
3 months ago
icon.svg
3 months ago
index.js
3 months ago
index.php
3 months ago
save.js
3 months ago
style.scss
1 week ago
style.scss
116 lines
| 1 | @use 'utils/breakpoints' as *; |
| 2 | |
| 3 | /*-------------------------------------------*/ |
| 4 | /* CSS |
| 5 | /*-------------------------------------------*/ |
| 6 | /*-------------------------------------------*/ |
| 7 | /* .vk_icon |
| 8 | /*-------------------------------------------*/ |
| 9 | .vk_icon { |
| 10 | @media screen and (width < $md) { |
| 11 | margin-bottom: 1.5em; |
| 12 | } |
| 13 | } |
| 14 | .wp-block-vk-blocks-icon { //編集画面で負けるので� |
| 15 | �頭に追加 |
| 16 | .vk_icon_frame { |
| 17 | display: flex; |
| 18 | line-height: 1; |
| 19 | |
| 20 | &.text-center { |
| 21 | justify-content: center; |
| 22 | } |
| 23 | &.text-right { |
| 24 | justify-content: right; |
| 25 | } |
| 26 | } |
| 27 | .vk_icon { |
| 28 | &_border { |
| 29 | display: flex; |
| 30 | align-items: center; |
| 31 | justify-content: center; |
| 32 | width: 80px; |
| 33 | height: 80px; |
| 34 | border-radius: 50%; |
| 35 | } |
| 36 | &_link { |
| 37 | display: flex; |
| 38 | text-decoration: none; |
| 39 | &:hover { |
| 40 | opacity: .85; |
| 41 | text-decoration: none; |
| 42 | } |
| 43 | } |
| 44 | &_font { |
| 45 | // 中央寄せは親の flex で行うため transform を使わない |
| 46 | // → fa-rotate-* / fa-flip-* など FA の transform がそのまま効く |
| 47 | font-size: 36px; |
| 48 | margin-right: 0; |
| 49 | margin-left: 0; |
| 50 | } |
| 51 | } |
| 52 | |
| 53 | .is-style-outline { |
| 54 | .vk_icon_border { |
| 55 | background-color: transparent; |
| 56 | border: 1px solid currentColor; |
| 57 | } |
| 58 | } |
| 59 | |
| 60 | .vk_icon_frame:where(:not(.is-style-outline)):where(:not(.is-style-noline)) { |
| 61 | .vk_icon_font:where(:not([class*="has-vk-color-"])) { // x-t9で has-vk-color-* クラスに白がつくのでnotを追加 |
| 62 | color: #fff; |
| 63 | } |
| 64 | } |
| 65 | |
| 66 | // old class before key-color START >>> |
| 67 | .vk_icon { |
| 68 | &_align { |
| 69 | &_center { |
| 70 | justify-content: center; |
| 71 | } |
| 72 | &_right { |
| 73 | justify-content: right; |
| 74 | } |
| 75 | } |
| 76 | |
| 77 | &_border { |
| 78 | &_frame { |
| 79 | background-color: transparent; |
| 80 | border-width: 1px; |
| 81 | border-style: solid; |
| 82 | } |
| 83 | } |
| 84 | } |
| 85 | |
| 86 | div:where(:not(.is-style-outline)):where(:not(.is-style-noline)) { |
| 87 | .vk_icon_border:where(:not(.vk_icon_border_frame)):where(:not(.vk_icon_border_none)) { |
| 88 | .vk_icon_font:where(:not([class*="has-vk-color-"])) { // x-t9で has-vk-color-* クラスに白がつくのでnotを追加 |
| 89 | color: #fff; |
| 90 | } |
| 91 | } |
| 92 | } |
| 93 | } |
| 94 | |
| 95 | |
| 96 | // デフォルトのカラー |
| 97 | .wp-block-vk-blocks-icon { |
| 98 | .vk_icon_frame:not(.is-style-outline):not(.is-style-noline) { |
| 99 | .vk_icon_border:not(.has-background) { |
| 100 | background-color: #337ab7; |
| 101 | } |
| 102 | } |
| 103 | |
| 104 | .is-style-noline { |
| 105 | .vk_icon_border:not(.has-text-color) { |
| 106 | color: #337ab7; |
| 107 | } |
| 108 | } |
| 109 | |
| 110 | .is-style-outline { |
| 111 | .vk_icon_border:not(.has-text-color) { |
| 112 | color: #337ab7; |
| 113 | } |
| 114 | } |
| 115 | } |
| 116 |