CARVIEW |
Select Language
HTTP/2 200
date: Sat, 11 Oct 2025 23:40:25 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
x-repository-download: git clone https://github.com/WordPress/gutenberg.git
etag: W/"6ae03dd47650c7ed35e22093c4eee753"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com github.githubassets.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com wss://alive-staging.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com marketplace-screenshots.githubusercontent.com/ copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=v5vfb1t5gufWO%2F8aCBhhhejkT2vVXebd88FBKrh6fkxpF37Wm6pS%2FtqKYGsCwg089EIPRG7K4o8CwP%2Fx27zuu7AstzJMHX4s8RQFoztKBVIv%2BLwuSa03APYVKQDjm8vr2Qrdq4OqEKOW0lab3F7Te47L0QJ0c8XR0%2B1zUTFtfaEU7zfy23NV41Fh2A1XcvLhgmBKtVE6saZ49I7TN7Mg1ImEGMD3tD7CbaVY5zFlaWPaUQhoQkXUrGerRaLwsQ0TMZ1Icy%2Fco4HuX%2FphOUxaSQ%3D%3D--byktM4yNIVWiBuom--aaoo2jK%2Fr6DHTFB7%2BTTzNg%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.377082161.1760226024; Path=/; Domain=github.com; Expires=Sun, 11 Oct 2026 23:40:24 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Sun, 11 Oct 2026 23:40:24 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: B70A:1FDE52:AC1010:E4767A:68EAEAE8
Block API: Add block visibility control support and UI (#71203) · WordPress/gutenberg@7feff31 · GitHub




authored
Copy file name to clipboard
Copy file name to clipboardExpand all lines: docs/reference-guides/core-blocks.md
Copy file name to clipboard
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/block.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/content.scss
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/use-block-props/index.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-settings-menu-controls/index.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-toolbar/index.js
Copy file name to clipboard
Skip to content
Navigation Menu
{{ message }}
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Commit 7feff31
Block API: Add block visibility control support and UI (#71203)
* Block API: Add block visibility control support and UI
* Render hidden block block
* Remove unused code
* Always hide block when it's not selected
* Extend existing isBlockVisible selector and use it
* Revert "Extend existing isBlockVisible selector and use it"
This reverts commit c3f7135.
* Remove SCSS import statement
* Use "isBlockHidden"
* Remove useBlockVisibility hook
* useBlockDropZone: Filter out blocks that are hidden
* Remove useBlockVisibility hook
* Update doc
* Show hidden block placeholder when dragging
* Revert "Show hidden block placeholder when dragging"
This reverts commit 2bfa54e.
* Show block toolbar button only when editing mode is default
* Process metadata updates for multiple blocks at once
* Preserve block visibility metadata in block transforms
* Remove support from schema and docs
* Add experiments setting
* Make Block Visibility as experiment feature
* Rename __experimentalBlockVisibility to blockVisibility
* Fix: other metadata attributes get stripped when toggling via the toolbar
* Show block toolbar button when multiple blocks are selected
* Fix incorrect block.json definition
* Apply opacity to hidden and selected blocks
* Revert "Apply opacity to hidden and selected blocks"
This reverts commit 5596f83.
* Provide blockVilibility metadata to preview context
* Accordion Header, Accordion Panel: disable blockVisibility support
* Visually hide block
* Stabilize feature
* Add backport changelog
* Update server side function
* Use "visibility:hidden" to visually hide blocks
* Combine multiple useSelect call into one
* Reset styles from hidden blocks
* Update lib/block-supports/block-visibility.php
Co-authored-by: Mukesh Panchal <mukeshpanchal27@users.noreply.github.com>
* Better behavior for hidden blocks
---------
Co-authored-by: t-hamano <wildworks@git.wordpress.org>
Co-authored-by: tyxla <tyxla@git.wordpress.org>
Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
Co-authored-by: talldan <talldanwp@git.wordpress.org>
Co-authored-by: sunyatasattva <sunyatasattva@git.wordpress.org>
Co-authored-by: mukeshpanchal27 <mukesh27@git.wordpress.org>
Co-authored-by: jasmussen <joen@git.wordpress.org>
Co-authored-by: annezazu <annezazu@git.wordpress.org>
Co-authored-by: supernovia <supernovia@git.wordpress.org>
Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
Co-authored-by: jameskoster <jameskoster@git.wordpress.org>1 parent 98386bd commit 7feff31Copy full SHA for 7feff31
File tree
Expand file treeCollapse file tree
23 files changed
+354
-33
lines changedFilter options
- backport-changelog/6.9
- docs/reference-guides
- lib
- block-supports
- packages
- block-editor/src
- components
- block-list
- use-block-props
- block-settings-menu-controls
- block-toolbar
- block-visibility
- list-view
- use-block-drop-zone
- store
- block-library/src
- accordion-header
- accordion-panel
- block
- pattern
- template-part
- utils
Expand file treeCollapse file tree
23 files changed
+354
-33
lines changedCollapse file: backport-changelog/6.9/10110.md
backport-changelog/6.9/10110.md
Copy file name to clipboard+3Lines changed: 3 additions & 0 deletions
- Display the source diff
- Display the rich diff
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + |
Collapse file: docs/reference-guides/core-blocks.md
docs/reference-guides/core-blocks.md
Copy file name to clipboardExpand all lines: docs/reference-guides/core-blocks.md+5-5Lines changed: 5 additions & 5 deletions
- Display the source diff
- Display the rich diff
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
39 | 39 |
| |
40 | 40 |
| |
41 | 41 |
| |
42 |
| - | |
| 42 | + | |
43 | 43 |
| |
44 | 44 |
| |
45 | 45 |
| |
| |||
50 | 50 |
| |
51 | 51 |
| |
52 | 52 |
| |
53 |
| - | |
| 53 | + | |
54 | 54 |
| |
55 | 55 |
| |
56 | 56 |
| |
| |||
86 | 86 |
| |
87 | 87 |
| |
88 | 88 |
| |
89 |
| - | |
| 89 | + | |
90 | 90 |
| |
91 | 91 |
| |
92 | 92 |
| |
| |||
585 | 585 |
| |
586 | 586 |
| |
587 | 587 |
| |
588 |
| - | |
| 588 | + | |
589 | 589 |
| |
590 | 590 |
| |
591 | 591 |
| |
| |||
975 | 975 |
| |
976 | 976 |
| |
977 | 977 |
| |
978 |
| - | |
| 978 | + | |
979 | 979 |
| |
980 | 980 |
| |
981 | 981 |
| |
|
Collapse file: lib/block-supports/block-visibility.php
lib/block-supports/block-visibility.php
Copy file name to clipboard+32Lines changed: 32 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + |
Collapse file: lib/load.php
+1Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
162 | 162 |
| |
163 | 163 |
| |
164 | 164 |
| |
| 165 | + | |
165 | 166 |
| |
166 | 167 |
| |
167 | 168 |
| |
|
Collapse file: packages/block-editor/src/components/block-list/block.js
packages/block-editor/src/components/block-list/block.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/block.js+16Lines changed: 16 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
624 | 624 |
| |
625 | 625 |
| |
626 | 626 |
| |
| 627 | + | |
627 | 628 |
| |
628 | 629 |
| |
629 | 630 |
| |
| |||
632 | 633 |
| |
633 | 634 |
| |
634 | 635 |
| |
| 636 | + | |
| 637 | + | |
| 638 | + | |
635 | 639 |
| |
636 | 640 |
| |
637 | 641 |
| |
| |||
705 | 709 |
| |
706 | 710 |
| |
707 | 711 |
| |
| 712 | + | |
708 | 713 |
| |
709 | 714 |
| |
710 | 715 |
| |
| |||
747 | 752 |
| |
748 | 753 |
| |
749 | 754 |
| |
| 755 | + | |
750 | 756 |
| |
751 | 757 |
| |
752 | 758 |
| |
| |||
795 | 801 |
| |
796 | 802 |
| |
797 | 803 |
| |
| 804 | + | |
798 | 805 |
| |
799 | 806 |
| |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
800 | 816 |
| |
801 | 817 |
| |
802 | 818 |
| |
|
Collapse file: packages/block-editor/src/components/block-list/content.scss
packages/block-editor/src/components/block-list/content.scss
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/content.scss+19Lines changed: 19 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
93 | 93 |
| |
94 | 94 |
| |
95 | 95 |
| |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
96 | 115 |
| |
97 | 116 |
| |
98 | 117 |
| |
|
Collapse file: packages/block-editor/src/components/block-list/use-block-props/index.js
packages/block-editor/src/components/block-list/use-block-props/index.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-list/use-block-props/index.js+2Lines changed: 2 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
101 | 101 |
| |
102 | 102 |
| |
103 | 103 |
| |
| 104 | + | |
104 | 105 |
| |
105 | 106 |
| |
106 | 107 |
| |
| |||
183 | 184 |
| |
184 | 185 |
| |
185 | 186 |
| |
| 187 | + | |
186 | 188 |
| |
187 | 189 |
| |
188 | 190 |
| |
|
Collapse file: packages/block-editor/src/components/block-settings-menu-controls/index.js
packages/block-editor/src/components/block-settings-menu-controls/index.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-settings-menu-controls/index.js+21-1Lines changed: 21 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
6 | 6 |
| |
7 | 7 |
| |
8 | 8 |
| |
| 9 | + | |
9 | 10 |
| |
10 | 11 |
| |
11 | 12 |
| |
| |||
20 | 21 |
| |
21 | 22 |
| |
22 | 23 |
| |
| 24 | + | |
23 | 25 |
| |
24 | 26 |
| |
25 | 27 |
| |
26 | 28 |
| |
27 |
| - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
28 | 35 |
| |
29 | 36 |
| |
| 37 | + | |
30 | 38 |
| |
31 | 39 |
| |
32 | 40 |
| |
| |||
38 | 46 |
| |
39 | 47 |
| |
40 | 48 |
| |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
41 | 54 |
| |
42 | 55 |
| |
43 | 56 |
| |
| |||
49 | 62 |
| |
50 | 63 |
| |
51 | 64 |
| |
| 65 | + | |
| 66 | + | |
52 | 67 |
| |
53 | 68 |
| |
54 | 69 |
| |
| |||
93 | 108 |
| |
94 | 109 |
| |
95 | 110 |
| |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
96 | 116 |
| |
97 | 117 |
| |
98 | 118 |
| |
|
Collapse file: packages/block-editor/src/components/block-toolbar/index.js
packages/block-editor/src/components/block-toolbar/index.js
Copy file name to clipboardExpand all lines: packages/block-editor/src/components/block-toolbar/index.js+9Lines changed: 9 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
28 | 28 |
| |
29 | 29 |
| |
30 | 30 |
| |
| 31 | + | |
31 | 32 |
| |
32 | 33 |
| |
33 | 34 |
| |
| |||
73 | 74 |
| |
74 | 75 |
| |
75 | 76 |
| |
| 77 | + | |
76 | 78 |
| |
77 | 79 |
| |
78 | 80 |
| |
| |||
163 | 165 |
| |
164 | 166 |
| |
165 | 167 |
| |
| 168 | + | |
166 | 169 |
| |
167 | 170 |
| |
168 | 171 |
| |
| |||
227 | 230 |
| |
228 | 231 |
| |
229 | 232 |
| |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
230 | 239 |
| |
231 | 240 |
| |
232 | 241 |
| |
|
Collapse file: packages/block-editor/src/components/block-visibility/index.js
packages/block-editor/src/components/block-visibility/index.js
Copy file name to clipboard+2Lines changed: 2 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + | |
| 2 | + |
You can’t perform that action at this time.
0 commit comments