Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

【2人目確認待ち】フォトフレーム傾きを拡大した時の傾きをリセット #1906

Merged
merged 10 commits into from
Feb 2, 2024
1 change: 1 addition & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ e.g.
1. VK Blocks examples.

== Changelog ==
[ Bug Fix ][ Image ]Fixed a bug in the photo frame with activated zoom in the image block styled 'photoFrame-tilt'

= 1.68.0 =
[ Add Function ][ Dynamic Text (Pro) ] Add feature to display logged-in username.
Expand Down
38 changes: 34 additions & 4 deletions src/extensions/core/image/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ $border_primary: 1px solid #e5e5e5;
width:auto;
}
figcaption {
display: block;
display: block !important; //管理画面で負けるので important 追加
margin: 8px 0 0;
}
}
Expand Down Expand Up @@ -58,8 +58,6 @@ $border_primary: 1px solid #e5e5e5;

//左寄せ、右寄せが未指定の場合はfigureに.is-style-vk-image のクラス名が付く
//figure.wp-block-imageの「.wp-block-image」をつけないと、角丸2のスタイルがつかないので追加


figure.wp-block-image{
// width: fit-content;
&.is-style-vk-image {
Expand Down Expand Up @@ -123,7 +121,8 @@ figure.wp-block-image{
}
}

//左寄せ、右寄せを指定した場合はdivのほうに.is-style-vk-image のクラス名が付くので、以下を追加する必要がある
//theme.json が有効時、左寄せ・右寄せを指定した場合はdivのほうに.is-style-vk-image のクラス名が付くので、以下を追加する必要がある。
//このdivのラッパーはtheme.json が無効の場合はdivラッパーが削除される。
.wp-block-image{
&.is-style-vk-image {
&-rounded figure{
Expand Down Expand Up @@ -204,3 +203,34 @@ figure.wp-block-image{
}
}
}

//「フォトフレーム傾き左」「フォトフレーム傾き右」で「クリックで拡大」をONにした時、拡大された画像の一部が欠けるので、拡大された時にフォトフレームの傾きをリセット
.wp-lightbox-overlay.zoom.active {
figure.wp-block-image{
&.is-style-vk-image {
&-photoFrame-tilt-right{
transform: none;
}

&-photoFrame-tilt-left{
transform: none;
}
}
}
// theme.json が有効時、左寄せ・右寄せを指定した場合はdivでラッパーされるので追加
.wp-block-image{
&.is-style-vk-image {
&-photoFrame-tilt-right, &-photoFrame-tilt-right figure{
&.alignleft, &.alignright, &.aligncenter{
transform: none;
}
}

&-photoFrame-tilt-left, &-photoFrame-tilt-left figure{
&.alignleft, &.alignright, &.aligncenter{
transform: none;
}
}
}
}
}
Loading