PluginProbe
Blockenberg — 600+ Advanced Gutenberg Blocks & AI Agent for WordPress Block Editor / 2.0.7
Blockenberg — 600+ Advanced Gutenberg Blocks & AI Agent for WordPress Block Editor v2.0.7
2.0.13 2.0.12 2.0.11 2.0.10 2.0.9 trunk 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 2.0.7 2.0.8
blockenberg / blocks / styled-list / style.css

style.css in Blockenberg — 600+ Advanced Gutenberg Blocks & AI Agent for WordPress Block Editor 2.0.7, at blocks/styled-list/style.css

411 lines 14.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /* ========================================
2 Styled List Block
3 Prefix: bkbg-sl-
4 ======================================== */
5
6 /* ── CSS Custom Properties ────────────────────────────────────────────────── */
7 .bkbg-sl-wrap {
8 --bkbg-sl-gap: 12px;
9 --bkbg-sl-col-gap: 32px;
10 --bkbg-sl-columns: 1;
11 --bkbg-sl-icon-size: 18px;
12 --bkbg-sl-icon-color: #3b82f6;
13 --bkbg-sl-icon-bg: #dbeafe;
14 --bkbg-sl-icon-bg-size: 34px;
15 --bkbg-sl-icon-radius: 50%;
16 --bkbg-sl-item-padding: 10px 14px;
17 --bkbg-sl-item-bg: transparent;
18 --bkbg-sl-item-bg-hover: transparent;
19 --bkbg-sl-item-brd-w: 0px;
20 --bkbg-sl-item-brd-color: #e2e8f0;
21 --bkbg-sl-item-brd-style: solid;
22 --bkbg-sl-item-radius: 0px;
23 --bkbg-sl-divider-color: #e2e8f0;
24 --bkbg-sl-divider-w: 1px;
25 --bkbg-sl-font-size: 16px;
26 --bkbg-sl-font-weight: 400;
27 --bkbg-sl-line-height: 1.6;
28 --bkbg-sl-text-color: #374151;
29 --bkbg-sl-desc-size: 14px;
30 --bkbg-sl-desc-weight: 400;
31 --bkbg-sl-desc-color: #6b7280;
32
33 list-style: none;
34 margin: 0;
35 padding: 0;
36 display: flex;
37 flex-direction: column;
38 gap: var(--bkbg-sl-gap);
39 }
40
41 /* ── Layout Variants ──────────────────────────────────────────────────────── */
42
43 /* Grid – 2 columns (default) */
44 .bkbg-sl-wrap[data-list-style="grid"] {
45 display: grid;
46 grid-template-columns: repeat(2, 1fr);
47 column-gap: var(--bkbg-sl-col-gap);
48 }
49
50 /* Grid – custom columns */
51 .bkbg-sl-wrap[data-list-style="grid-custom"] {
52 display: grid;
53 grid-template-columns: repeat(var(--bkbg-sl-columns), 1fr);
54 column-gap: var(--bkbg-sl-col-gap);
55 }
56
57 /* Horizontal – single wrapping row */
58 .bkbg-sl-wrap[data-list-style="horizontal"] {
59 flex-direction: row;
60 flex-wrap: wrap;
61 column-gap: var(--bkbg-sl-col-gap);
62 align-items: flex-start;
63 }
64
65 .bkbg-sl-wrap[data-list-style="horizontal"] .bkbg-sl-li {
66 flex: 0 0 auto;
67 }
68
69 /* ── List Item ────────────────────────────────────────────────────────────── */
70 .bkbg-sl-li {
71 margin: 0;
72 padding: 0;
73 list-style: none;
74 }
75
76 .bkbg-sl-item {
77 display: flex;
78 align-items: center;
79 gap: 12px;
80 padding: var(--bkbg-sl-item-padding);
81 background: var(--bkbg-sl-item-bg);
82 border: var(--bkbg-sl-item-brd-w) var(--bkbg-sl-item-brd-style) var(--bkbg-sl-item-brd-color);
83 border-radius: var(--bkbg-sl-item-radius);
84 transition: background 0.2s ease, box-shadow 0.2s ease;
85 position: relative;
86 }
87
88 .bkbg-sl-item:hover {
89 background: var(--bkbg-sl-item-bg-hover);
90 }
91
92 /* Shadow variant */
93 .bkbg-sl-item.has-shadow {
94 box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
95 }
96
97 /* ── Icon alignment ───────────────────────────────────────────────────────── */
98 .bkbg-sl-wrap[data-icon-align="center"] .bkbg-sl-item {
99 align-items: center;
100 }
101
102 .bkbg-sl-wrap[data-icon-align="top"] .bkbg-sl-item {
103 align-items: flex-start;
104 }
105
106 /* Icon on the right – reverse order */
107 .bkbg-sl-wrap[data-icon-pos="right"] .bkbg-sl-item {
108 flex-direction: row-reverse;
109 }
110
111 /* ── Text alignment ───────────────────────────────────────────────────────── */
112 .bkbg-sl-wrap[data-align="center"] .bkbg-sl-item {
113 justify-content: center;
114 text-align: center;
115 }
116
117 .bkbg-sl-wrap[data-align="right"] .bkbg-sl-item {
118 justify-content: flex-end;
119 text-align: right;
120 }
121
122 /* ── Divider between items ────────────────────────────────────────────────── */
123 .bkbg-sl-wrap[data-divider="1"] .bkbg-sl-li + .bkbg-sl-li {
124 border-top: var(--bkbg-sl-divider-w) solid var(--bkbg-sl-divider-color);
125 padding-top: var(--bkbg-sl-gap);
126 margin-top: 0;
127 }
128
129 /* When dividers enabled, remove the wrap gap and use padding instead */
130 .bkbg-sl-wrap[data-divider="1"] {
131 gap: 0;
132 }
133
134 .bkbg-sl-wrap[data-divider="1"] .bkbg-sl-li:first-child {
135 padding-top: 0;
136 border-top: none;
137 }
138
139 .bkbg-sl-wrap[data-divider="1"] .bkbg-sl-li {
140 padding-top: var(--bkbg-sl-gap);
141 }
142
143 /* ── Icon wrapper ─────────────────────────────────────────────────────────── */
144 .bkbg-sl-icon-wrap {
145 display: inline-flex;
146 align-items: center;
147 justify-content: center;
148 flex-shrink: 0;
149 color: var(--bkbg-sl-icon-color);
150 width: var(--bkbg-sl-icon-size);
151 height: var(--bkbg-sl-icon-size);
152 }
153
154 /* ── Icon element ─────────────────────────────────────────────────────────── */
155 .bkbg-sl-icon {
156 display: inline-flex;
157 align-items: center;
158 justify-content: center;
159 width: var(--bkbg-sl-icon-size);
160 height: var(--bkbg-sl-icon-size);
161 color: inherit;
162 flex-shrink: 0;
163 }
164
165 .bkbg-sl-icon svg {
166 width: 100%;
167 height: 100%;
168 fill: currentColor;
169 display: block;
170 }
171
172 /* Dashicon icon sizing */
173 .bkbg-sl-icon .dashicons {
174 font-size: var(--bkbg-sl-icon-size);
175 width: var(--bkbg-sl-icon-size);
176 height: var(--bkbg-sl-icon-size);
177 line-height: 1;
178 }
179
180 /* Custom image icon */
181 .bkbg-sl-icon .bkbg-sl-img-icon {
182 width: var(--bkbg-sl-icon-size);
183 height: var(--bkbg-sl-icon-size);
184 object-fit: contain;
185 display: block;
186 border-radius: 2px;
187 }
188
189 /* Remove colour tinting on image icons */
190 .bkbg-sl-wrap[data-icon-type="custom-image"] .bkbg-sl-icon {
191 color: transparent;
192 }
193
194 /* ── Custom character icon ─────────────────────────────────────────────────── */
195 .bkbg-sl-icon .bkbg-sl-char {
196 font-size: var(--bkbg-sl-icon-size);
197 line-height: 1;
198 font-weight: 700;
199 display: inline-flex;
200 align-items: center;
201 }
202
203 /* Ordered number */
204 .bkbg-sl-icon .bkbg-sl-num {
205 font-size: calc(var(--bkbg-sl-icon-size) * 0.75);
206 font-weight: 700;
207 line-height: 1;
208 display: inline-flex;
209 align-items: center;
210 }
211
212 /* ── Icon Shapes ──────────────────────────────────────────────────────────── */
213
214 /* Circle — Filled */
215 .bkbg-sl-wrap[data-icon-shape="circle-filled"] .bkbg-sl-icon-wrap {
216 width: var(--bkbg-sl-icon-bg-size);
217 height: var(--bkbg-sl-icon-bg-size);
218 border-radius: 50%;
219 background: var(--bkbg-sl-icon-bg);
220 }
221
222 /* Circle — Outline */
223 .bkbg-sl-wrap[data-icon-shape="circle-outline"] .bkbg-sl-icon-wrap {
224 width: var(--bkbg-sl-icon-bg-size);
225 height: var(--bkbg-sl-icon-bg-size);
226 border-radius: 50%;
227 border: 2px solid currentColor;
228 }
229
230 /* Square — Filled */
231 .bkbg-sl-wrap[data-icon-shape="square-filled"] .bkbg-sl-icon-wrap {
232 width: var(--bkbg-sl-icon-bg-size);
233 height: var(--bkbg-sl-icon-bg-size);
234 border-radius: 4px;
235 background: var(--bkbg-sl-icon-bg);
236 }
237
238 /* Square — Outline */
239 .bkbg-sl-wrap[data-icon-shape="square-outline"] .bkbg-sl-icon-wrap {
240 width: var(--bkbg-sl-icon-bg-size);
241 height: var(--bkbg-sl-icon-bg-size);
242 border-radius: 4px;
243 border: 2px solid currentColor;
244 }
245
246 /* Rounded Square — Filled */
247 .bkbg-sl-wrap[data-icon-shape="rounded-filled"] .bkbg-sl-icon-wrap {
248 width: var(--bkbg-sl-icon-bg-size);
249 height: var(--bkbg-sl-icon-bg-size);
250 border-radius: var(--bkbg-sl-icon-radius);
251 background: var(--bkbg-sl-icon-bg);
252 }
253
254 /* Rounded Square — Outline */
255 .bkbg-sl-wrap[data-icon-shape="rounded-outline"] .bkbg-sl-icon-wrap {
256 width: var(--bkbg-sl-icon-bg-size);
257 height: var(--bkbg-sl-icon-bg-size);
258 border-radius: var(--bkbg-sl-icon-radius);
259 border: 2px solid currentColor;
260 }
261
262 /* ── Content area ─────────────────────────────────────────────────────────── */
263 .bkbg-sl-content {
264 flex: 1;
265 min-width: 0;
266 }
267
268 /* ── Text ─────────────────────────────────────────────────────────────────── */
269 .bkbg-sl-text {
270 font-family: var(--bksl-tx-font-family, inherit);
271 font-size: var(--bksl-tx-font-size-d, var(--bkbg-sl-font-size, 16px));
272 line-height: var(--bksl-tx-line-height-d, var(--bkbg-sl-line-height, 1.6));
273 letter-spacing: var(--bksl-tx-letter-spacing-d, normal);
274 word-spacing: var(--bksl-tx-word-spacing-d, normal);
275 font-weight: var(--bksl-tx-font-weight, var(--bkbg-sl-font-weight, 400));
276 font-style: var(--bksl-tx-font-style, normal);
277 text-decoration: var(--bksl-tx-text-decoration, none);
278 text-transform: var(--bksl-tx-text-transform, none);
279 color: var(--bkbg-sl-text-color);
280 margin: 0;
281 }
282
283 .bkbg-sl-text p {
284 margin: 0;
285 }
286
287 /* ── Description ──────────────────────────────────────────────────────────── */
288 .bkbg-sl-desc {
289 font-family: var(--bksl-ds-font-family, inherit);
290 font-size: var(--bksl-ds-font-size-d, var(--bkbg-sl-desc-size, 14px));
291 line-height: var(--bksl-ds-line-height-d, 1.5);
292 letter-spacing: var(--bksl-ds-letter-spacing-d, normal);
293 word-spacing: var(--bksl-ds-word-spacing-d, normal);
294 font-weight: var(--bksl-ds-font-weight, var(--bkbg-sl-desc-weight, 400));
295 font-style: var(--bksl-ds-font-style, normal);
296 text-decoration: var(--bksl-ds-text-decoration, none);
297 text-transform: var(--bksl-ds-text-transform, none);
298 color: var(--bkbg-sl-desc-color);
299 margin: 4px 0 0;
300 }
301
302 .bkbg-sl-desc p {
303 margin: 0;
304 }
305
306 /* ── Responsive ───────────────────────────────────────────────────────────── */
307 @media (max-width: 1024px) {
308 .bkbg-sl-text {
309 font-size: var(--bksl-tx-font-size-t, var(--bksl-tx-font-size-d, var(--bkbg-sl-font-size, 16px)));
310 line-height: var(--bksl-tx-line-height-t, var(--bksl-tx-line-height-d, var(--bkbg-sl-line-height, 1.6)));
311 letter-spacing: var(--bksl-tx-letter-spacing-t, var(--bksl-tx-letter-spacing-d, normal));
312 word-spacing: var(--bksl-tx-word-spacing-t, var(--bksl-tx-word-spacing-d, normal));
313 }
314 .bkbg-sl-desc {
315 font-size: var(--bksl-ds-font-size-t, var(--bksl-ds-font-size-d, var(--bkbg-sl-desc-size, 14px)));
316 line-height: var(--bksl-ds-line-height-t, var(--bksl-ds-line-height-d, 1.5));
317 letter-spacing: var(--bksl-ds-letter-spacing-t, var(--bksl-ds-letter-spacing-d, normal));
318 word-spacing: var(--bksl-ds-word-spacing-t, var(--bksl-ds-word-spacing-d, normal));
319 }
320 }
321
322 @media (max-width: 767px) {
323 .bkbg-sl-text {
324 font-size: var(--bksl-tx-font-size-m, var(--bksl-tx-font-size-t, var(--bksl-tx-font-size-d, var(--bkbg-sl-font-size, 16px))));
325 line-height: var(--bksl-tx-line-height-m, var(--bksl-tx-line-height-t, var(--bksl-tx-line-height-d, var(--bkbg-sl-line-height, 1.6))));
326 letter-spacing: var(--bksl-tx-letter-spacing-m, var(--bksl-tx-letter-spacing-t, var(--bksl-tx-letter-spacing-d, normal)));
327 word-spacing: var(--bksl-tx-word-spacing-m, var(--bksl-tx-word-spacing-t, var(--bksl-tx-word-spacing-d, normal)));
328 }
329 .bkbg-sl-desc {
330 font-size: var(--bksl-ds-font-size-m, var(--bksl-ds-font-size-t, var(--bksl-ds-font-size-d, var(--bkbg-sl-desc-size, 14px))));
331 line-height: var(--bksl-ds-line-height-m, var(--bksl-ds-line-height-t, var(--bksl-ds-line-height-d, 1.5)));
332 letter-spacing: var(--bksl-ds-letter-spacing-m, var(--bksl-ds-letter-spacing-t, var(--bksl-ds-letter-spacing-d, normal)));
333 word-spacing: var(--bksl-ds-word-spacing-m, var(--bksl-ds-word-spacing-t, var(--bksl-ds-word-spacing-d, normal)));
334 }
335 }
336
337 @media (max-width: 768px) {
338 .bkbg-sl-wrap[data-list-style="grid"],
339 .bkbg-sl-wrap[data-list-style="grid-custom"] {
340 grid-template-columns: 1fr;
341 }
342
343 .bkbg-sl-wrap[data-list-style="horizontal"] {
344 flex-direction: column;
345 }
346 }
347
348 /* ── Editor-only styles ───────────────────────────────────────────────────── */
349 .editor-styles-wrapper .bkbg-sl-wrap {
350 /* Ensure ul resets inside editor too */
351 list-style: none;
352 padding: 0;
353 margin: 0;
354 }
355
356 .editor-styles-wrapper .bkbg-sl-li {
357 list-style: none;
358 }
359
360 /* Focused item highlight */
361 .editor-styles-wrapper .bkbg-sl-item.is-focused {
362 outline: 2px solid #3b82f6;
363 outline-offset: 2px;
364 border-radius: var(--bkbg-sl-item-radius);
365 }
366
367 /* Item toolbar (editor only) */
368 .bkbg-sl-item-toolbar {
369 position: absolute;
370 top: -32px;
371 left: 0;
372 display: flex;
373 align-items: center;
374 gap: 2px;
375 background: #1e1e1e;
376 border-radius: 4px;
377 padding: 2px 4px;
378 z-index: 10;
379 box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
380 }
381
382 .bkbg-sl-item-toolbar .components-button {
383 color: #fff !important;
384 min-width: 28px;
385 height: 28px;
386 padding: 0 6px;
387 }
388
389 .bkbg-sl-item-toolbar .components-button:hover {
390 background: rgba(255, 255, 255, 0.15) !important;
391 }
392
393 .bkbg-sl-item-toolbar .is-destructive {
394 color: #f87171 !important;
395 }
396
397 .bkbg-sl-item-toolbar .is-destructive:hover {
398 background: rgba(248, 113, 113, 0.15) !important;
399 }
400
401 /* ── Editor: RichText placeholders ───────────────────────────────────────── */
402 .editor-styles-wrapper .bkbg-sl-text[data-is-placeholder-visible="true"]::before,
403 .editor-styles-wrapper .bkbg-sl-desc[data-is-placeholder-visible="true"]::before {
404 opacity: 0.4;
405 }
406
407 /* ── Editor: item actions bar ────────────────────────────────────────────── */
408 .editor-styles-wrapper .bkbg-editor-actions {
409 margin-top: 8px;
410 }
411