block-context
2 years ago
blocks
1 year ago
components
1 year ago
dynamic-tags
1 year ago
editor
1 year ago
editor-sidebar
1 year ago
extend
1 year ago
hoc
1 year ago
hooks
1 year ago
pattern-library
1 year ago
settings
1 year ago
shared
1 year ago
store
1 year ago
utils
1 year ago
_common.scss
1 year ago
blocks.js
2 years ago
dashboard.js
1 year ago
dashboard.scss
1 year ago
editor-sidebar.js
2 years ago
editor.js
1 year ago
packages.scss
1 year ago
pattern-library.js
2 years ago
settings.js
1 year ago
settings.scss
1 year ago
settings.scss
262 lines
| 1 | @use "sass:math"; |
| 2 | $settings-container-width: 750px; |
| 3 | |
| 4 | .gblocks-dashboard-wrap { |
| 5 | margin: 0; |
| 6 | overflow: hidden; |
| 7 | } |
| 8 | |
| 9 | .gblocks-dashboard-header { |
| 10 | $padding-inline: 20px; |
| 11 | $padding-inline-half: math.div($padding-inline, 2); |
| 12 | align-items: center; |
| 13 | background: #fff; |
| 14 | border-bottom: 1px solid #e2e4e7; |
| 15 | display: flex; |
| 16 | justify-content: space-between; |
| 17 | overflow-x: auto; |
| 18 | padding-right: $padding-inline; |
| 19 | text-align: center; |
| 20 | |
| 21 | // Add the padding from tablet widths to mobile so the header doesn't overlap the admin bar. |
| 22 | @media (max-width: 600px) { |
| 23 | padding-top: var(--wp-admin--admin-bar--height); |
| 24 | } |
| 25 | |
| 26 | &-title { |
| 27 | background: #fff; |
| 28 | left: 0; |
| 29 | padding: 0; |
| 30 | padding-left: $padding-inline; |
| 31 | position: sticky; |
| 32 | } |
| 33 | |
| 34 | h1 { |
| 35 | font-size: 17px; |
| 36 | font-weight: 600; |
| 37 | padding-bottom: 0; |
| 38 | display: flex; |
| 39 | align-items: center; |
| 40 | |
| 41 | svg { |
| 42 | width: 1em; |
| 43 | height: 1em; |
| 44 | padding-right: 10px; |
| 45 | fill: #006eb7; |
| 46 | } |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | .gblocks-navigation { |
| 51 | background: #fff; |
| 52 | display: flex; |
| 53 | |
| 54 | a { |
| 55 | padding: 1rem; |
| 56 | display: flex; |
| 57 | align-items: center; |
| 58 | color: inherit; |
| 59 | text-decoration: none; |
| 60 | |
| 61 | &.active { |
| 62 | font-weight: 600; |
| 63 | box-shadow: inset 0 -3px #007cba; |
| 64 | } |
| 65 | } |
| 66 | } |
| 67 | |
| 68 | .generateblocks-settings-area { |
| 69 | .components-placeholder.gblocks-settings-placeholder { |
| 70 | margin-top: 20px; |
| 71 | margin-left: auto; |
| 72 | margin-right: auto; |
| 73 | max-width: $settings-container-width; |
| 74 | background: #fff; |
| 75 | border: 1px solid #e2e4e7; |
| 76 | box-shadow: none; |
| 77 | } |
| 78 | |
| 79 | .generateblocks-settings-main { |
| 80 | margin-left: auto; |
| 81 | margin-right: auto; |
| 82 | max-width: $settings-container-width; |
| 83 | |
| 84 | .gblocks-action-button { |
| 85 | display: flex; |
| 86 | align-items: center; |
| 87 | } |
| 88 | |
| 89 | .gblocks-action-message { |
| 90 | padding-left: 10px; |
| 91 | opacity: 0; |
| 92 | transition: opacity 200ms ease-in-out; |
| 93 | color: green; |
| 94 | pointer-events: none; |
| 95 | |
| 96 | &.gblocks-action-message--show { |
| 97 | opacity: 1; |
| 98 | transition: opacity 200ms ease-in-out; |
| 99 | } |
| 100 | |
| 101 | &.gblocks-action-message--error { |
| 102 | color: red; |
| 103 | } |
| 104 | } |
| 105 | |
| 106 | /* Only needed until WP 5.6 */ |
| 107 | .gblocks-css-print-method { |
| 108 | .components-base-control__label { |
| 109 | display: block; |
| 110 | } |
| 111 | } |
| 112 | |
| 113 | .components-button .components-spinner { |
| 114 | margin: 0; |
| 115 | } |
| 116 | |
| 117 | .components-button.is-primary .components-spinner { |
| 118 | background: rgba(0, 0, 0, 0.1); |
| 119 | border-radius: 100%; |
| 120 | } |
| 121 | |
| 122 | .components-panel__body { |
| 123 | margin: 25px 0; |
| 124 | background: #fff; |
| 125 | border: 1px solid #e2e4e7; |
| 126 | |
| 127 | .components-panel__body-toggle { |
| 128 | border-bottom: 1px solid #d6e2ed; |
| 129 | } |
| 130 | |
| 131 | .gblocks-dashboard-panel-row-wrapper { |
| 132 | padding-top: 10px; |
| 133 | |
| 134 | & > *:last-child { |
| 135 | margin-bottom: 0; |
| 136 | } |
| 137 | } |
| 138 | |
| 139 | .components-panel__row { |
| 140 | padding: 0; |
| 141 | margin: 0 0 25px; |
| 142 | display: block; |
| 143 | |
| 144 | .components-base-control { |
| 145 | .components-base-control__help { |
| 146 | margin: 0; |
| 147 | } |
| 148 | |
| 149 | .components-base-control__field { |
| 150 | margin-bottom: 5px; |
| 151 | } |
| 152 | } |
| 153 | } |
| 154 | |
| 155 | .components-notice { |
| 156 | margin: 0 0 10px; |
| 157 | } |
| 158 | } |
| 159 | } |
| 160 | } |
| 161 | |
| 162 | .generateblocks-dashboard-page { |
| 163 | #wpcontent { |
| 164 | padding-left: 0; |
| 165 | } |
| 166 | |
| 167 | .update-nag { |
| 168 | margin-bottom: 20px; |
| 169 | margin-left: 22px; |
| 170 | } |
| 171 | |
| 172 | #wpbody-content .wrap { |
| 173 | padding: 0 20px; |
| 174 | margin: 0; |
| 175 | } |
| 176 | } |
| 177 | |
| 178 | .gblocks-units { |
| 179 | position: absolute; |
| 180 | top: 0; |
| 181 | right: 0; |
| 182 | font-size: 12px; |
| 183 | font-weight: bold; |
| 184 | } |
| 185 | |
| 186 | .gblocks-container-width { |
| 187 | position: relative; |
| 188 | } |
| 189 | |
| 190 | .gblocks-library { |
| 191 | margin-bottom: 1.5em; |
| 192 | |
| 193 | h3 { |
| 194 | font-size: 16px; |
| 195 | margin-bottom: 1em; |
| 196 | font-weight: 500; |
| 197 | } |
| 198 | |
| 199 | &:first-child { |
| 200 | margin-bottom: 2.5em; |
| 201 | } |
| 202 | } |
| 203 | |
| 204 | .gblocks-library-item { |
| 205 | display: flex; |
| 206 | gap: 24px; |
| 207 | justify-content: space-between; |
| 208 | align-items: center; |
| 209 | padding: 15px; |
| 210 | background: #ffffff; |
| 211 | flex-wrap: wrap; |
| 212 | |
| 213 | &:nth-child(even) { |
| 214 | background: #efefef; |
| 215 | } |
| 216 | |
| 217 | &__edit { |
| 218 | flex-basis: 100%; |
| 219 | display: flex; |
| 220 | flex-direction: column; |
| 221 | gap: 10px; |
| 222 | } |
| 223 | |
| 224 | &__name { |
| 225 | display: flex; |
| 226 | align-items: center; |
| 227 | gap: 10px; |
| 228 | |
| 229 | button.components-button { |
| 230 | min-width: 25px; |
| 231 | height: 25px; |
| 232 | width: 25px; |
| 233 | } |
| 234 | } |
| 235 | |
| 236 | &__actions { |
| 237 | display: flex; |
| 238 | align-items: center; |
| 239 | gap: 10px; |
| 240 | |
| 241 | button.components-button { |
| 242 | min-width: 25px; |
| 243 | height: 25px; |
| 244 | width: 25px; |
| 245 | } |
| 246 | |
| 247 | .components-toggle-control { |
| 248 | label { |
| 249 | font-size: 11px; |
| 250 | } |
| 251 | } |
| 252 | } |
| 253 | |
| 254 | .components-toggle-control { |
| 255 | margin-bottom: 0; |
| 256 | |
| 257 | .components-base-control__field { |
| 258 | margin-bottom: 0 !important; |
| 259 | } |
| 260 | } |
| 261 | } |
| 262 |