PluginProbe
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) / 1.8.13
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) v1.8.13
1.8.13.1 1.8.13 1.8.12.3 1.8.12.2 1.8.12.1 1.8.12 1.8.11.3 1.8.11.2 1.8.11.1 1.8.11 1.6.6 1.6.60 1.6.7 1.6.8 1.6.9 1.7.0 1.7.0.1 1.7.0.11 1.7.0.12 1.7.0.14 1.7.0.2 1.7.0.3 1.7.0.5 1.7.0.6 1.7.0.7 All 212 releases
charitable / includes / css-templates / admin / animal-sanctuary-colors.php

animal-sanctuary-colors.php in Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) 1.8.13, at includes/css-templates/admin/animal-sanctuary-colors.php

391 lines 12.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 // Exit if accessed directly.
4 if ( ! defined( 'ABSPATH' ) ) {
5 exit;
6 }
7
8 /**
9 * Display custom CSS.
10 *
11 * @package Charitable
12 * @author WP Charitable LLC
13 * @since 1.8.0
14 * @version 1.8.3.7
15 */
16
17 header( 'Content-type: text/css; charset: UTF-8' );
18
19 if ( ! function_exists( 'charitable_sanitize_hex_color' ) ) {
20 /**
21 * Sanitize a hex color.
22 *
23 * @param string $color The color to sanitize.
24 * @return string|null The sanitized color or null if the color is invalid.
25 */
26 function charitable_sanitize_hex_color( $color ) {
27 // Ensure the value is a string.
28 $color = trim( $color );
29
30 // Check if it's a valid 6-character hex color including the hash.
31 if ( preg_match( '/^#[a-fA-F0-9]{6}$/', $color ) ) {
32 return $color;
33 }
34
35 // Optionally return a default color or handle errors.
36 return null; // Or return default color.
37 }
38 }
39
40 if ( ! function_exists( 'charitable_esc_attr_php' ) ) {
41 /**
42 * Escapes a string for use in PHP.
43 *
44 * @param string $text The text to escape.
45 * @return string The escaped text.
46 */
47 function charitable_esc_attr_php( $text ) {
48 return htmlspecialchars( $text, ENT_QUOTES, 'UTF-8' );
49 }
50 }
51
52 // @codingStandardsIgnoreStart
53
54 $primary = isset( $_GET['p'] ) ? '#' . substr( preg_replace( '/[^A-Fa-f0-9]/', '', $_GET['p'] ), 0, 6 ) : '#805F93';
55 $secondary = isset( $_GET['s'] ) ? '#' . substr( preg_replace( '/[^A-Fa-f0-9]/', '', $_GET['s'] ), 0, 6 ) : '#1D1C1C';
56 $tertiary = isset( $_GET['t'] ) ? '#' . substr( preg_replace( '/[^A-Fa-f0-9]/', '', $_GET['t'] ), 0, 6 ) : '#808080';
57 $button = isset( $_GET['b'] ) ? '#' . substr( preg_replace( '/[^A-Fa-f0-9]/', '', $_GET['b'] ), 0, 6 ) : '#805F93';
58
59 $slug = 'animal-sanctuary'; // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- Template variable used in CSS selectors.
60 $wrapper = '.charitable-preview.charitable-builder-template-' . $slug . ' #charitable-design-wrap .charitable-campaign-preview'; // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- Template variable used in CSS selectors.
61
62 require_once dirname( __DIR__, 2 ) . '/admin/campaign-builder/templates/functions-campaign-templates.php';
63 ?>
64
65 .charitable-preview.charitable-builder-template-<?php echo $slug; ?> { /* everything wraps in this */
66
67 font-family: -apple-system, BlinkMacSystemFont, sans-serif;
68
69 }
70
71 /* this narrows things down a little to the preview area header/tabs */
72
73 <?php echo charitable_esc_attr_php( $wrapper ); ?> {
74 /* field items in preview area */
75 }
76
77 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field {
78 display: flex;
79 }
80 /* wide spread changes in header vs tabs */
81
82 <?php echo charitable_esc_attr_php( $wrapper ); ?> header {
83 background-color: <?php echo $tertiary; ?>;
84 color: #606060;
85 }
86 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h1,
87 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h2,
88 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h3,
89 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h4,
90 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h5,
91 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h6 {
92 color: <?php echo $secondary; ?>
93 }
94 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h1,
95 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h2,
96 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h3,
97 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h4,
98 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h5,
99 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content h6 {
100 color: <?php echo $primary; ?>;
101 }
102
103 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content > * {
104 color: black;
105 }
106
107 <?php echo charitable_esc_attr_php( $wrapper ); ?> header h5 {
108 font-size: 24px;
109 line-height: 28px;
110 }
111
112 <?php echo charitable_esc_attr_php( $wrapper ); ?> .placeholder {
113 padding: 0;
114 }
115
116 /* aligns */
117
118
119
120 /* column specifics */
121
122 <?php echo charitable_esc_attr_php( $wrapper ); ?> .column[data-column-id="0"] {
123 flex: 0 0 66%;
124 }
125 <?php echo charitable_esc_attr_php( $wrapper ); ?> .column[data-column-id="1"] {
126 border: 1px solid #ECECEC;
127 }
128
129 /* headlines in general */
130
131 <?php echo charitable_esc_attr_php( $wrapper ); ?> h5.charitable-field-preview-headline,
132 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-campaign-title,
133 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-headline {
134 color: <?php echo $primary; ?>;
135 }
136
137 /* field: campaign title */
138
139 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-campaign-title h1 {
140 margin: 5px 0 5px 0;
141 color: <?php echo $primary; ?>;
142 font-size: 27px;
143 line-height: 29px;
144 font-weight: 600;
145 }
146
147 /* field: campaign description */
148
149 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-campaign-description .charitable-campaign-builder-placeholder-preview-text {
150 padding: 0;
151 color: #202020;
152 }
153
154
155 /* field: text */
156
157 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-text .charitable-campaign-builder-placeholder-preview-text {
158 padding: 0;
159 color: #202020;
160 }
161 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-text h5.charitable-field-preview-headline {
162 color: <?php echo $primary; ?>;
163 }
164
165
166 /* field: button */
167
168 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-donate-button .charitable-field-preview-donate-button span.placeholder.button {
169 background-color: <?php echo $button; ?> !important;
170 border-color: <?php echo $button; ?> !important;
171 color: <?php echo charitable_get_constracting_text_color( $button ); ?>;
172 text-transform: uppercase;
173 border-radius: 10px;
174 margin-top: 0;
175 margin-bottom: 0;
176 width: 100%;
177 font-weight: 400;
178 min-height: 50px;
179 height: 50px;
180 font-size: 16px;
181 line-height: 50px;
182 }
183
184 /* field: photo */
185
186 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-photo .primary-image {
187 border: transparent;
188 border-radius: 0px;
189 }
190
191 /* field: photo */
192
193 <?php echo charitable_esc_attr_php( $wrapper ); ?> header .primary-image-container {
194 margin: 0;
195 padding: 0;
196 }
197
198 <?php echo charitable_esc_attr_php( $wrapper ); ?> .tab-content .primary-image-container {
199 margin: 0;
200 padding: 0;
201 }
202
203 /* field: progress bar */
204
205 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-progress-bar .progress-bar-info-row div.campaign-percent-raised {
206 color: #202020;
207 font-weight: 500;
208 font-size: 18px;
209 line-height: 21px;
210 }
211 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-progress-bar .progress-bar-info-row div.campaign-goal {
212 color: <?php echo $primary; ?>;
213 font-weight: 600;
214 font-size: 24px;
215 line-height: 28px;
216 }
217 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-progress-bar .progress {
218 border: 0;
219 padding: 0;
220 background-color: #E0E0E0;
221 border-radius: 5px;
222 margin-top: 15px;
223 }
224 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-progress-bar .progress-bar {
225 background-color: <?php echo $primary; ?>;
226 height: 8px !important;
227 border-radius: 5px;
228 text-align: right;
229 opacity: 1.0;
230 }
231 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-progress-bar .progress-bar span {
232 display: inline-block;
233 background-color: <?php echo $primary; ?>;
234 border-radius: 25px;
235 width: 25px;
236 height: 25px;
237 margin-right: -15px;
238 margin-top: -10px;
239 }
240
241 /* field: social linking */
242
243 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking {
244 display: table;
245 }
246
247 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking .charitable-field-preview-social-linking-headline-container {
248
249 }
250 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking .charitable-field-row {
251
252 }
253 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking .charitable-field-row:before {
254
255 }
256 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking .charitable-field-row div {
257
258 }
259 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking h5.charitable-field-preview-headline {
260
261 color: #24231E;
262
263 }
264 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking .charitable-placeholder {
265
266 }
267
268 /* field: social sharing */
269
270 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing {
271
272 }
273
274 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-preview-social-sharing-headline-container {
275
276 }
277 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-row {
278
279 }
280 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-row:before {
281
282 }
283 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-row div {
284
285 }
286 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing h5.charitable-field-preview-headline {
287
288 color: #24231E;
289
290 }
291 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-placeholder {
292
293 }
294
295 /* field: social sharing AND linking */
296
297 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-campaign-field.charitable-campaign-field-social-links .charitable-field-row .charitable-campaign-social-link,
298 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-row .charitable-campaign-social-link {
299
300 }
301 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking h5,
302 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing h5 {
303
304 }
305 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-linking,
306 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing {
307 border: 1px solid rgba(0, 0, 0, 0.20);
308 border-radius: 10px;
309 display: table;
310 width: 100%;
311 padding: 15px;
312 }
313 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-campaign-field.charitable-campaign-field-social-links .charitable-field-preview-social-linking img,
314 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-preview-social-sharing img {
315
316 }
317
318 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field.charitable-field-social-links .charitable-field-row .charitable-placeholder,
319 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-social-sharing .charitable-field-row .charitable-placeholder {
320 background-position: center;
321
322 border-radius: 40px;
323 padding: 20px;
324 background-repeat: no-repeat;
325 background-size: 25px;
326 border: 1px solid <?php echo $tertiary; ?>;
327
328
329 }
330
331 /* social icons */
332
333 <?php
334 // Include shared social icons CSS with dark icon style.
335 $icon_style = 'dark';
336 include dirname( __FILE__ ) . '/partials/social-icons.php';
337 ?>
338
339 /* field: campaign summary */
340
341 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary {
342 padding-left: 0;
343 padding-right: 0;
344 }
345 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary div {
346 color: #92918E;
347 font-weight: 400;
348 font-size: 14px;
349 line-height: 16px;
350 }
351 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary div span {
352 color: <?php echo $secondary; ?>;
353 font-weight: 600;
354 font-size: 32px;
355 line-height: 38px;
356 }
357 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary .campaign-summary-item {
358 border: 0;
359 margin-top: 5px;
360 margin-bottom: 5px;
361 text-transform: capitalize;
362 }
363 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary .campaign-summary-item.campaign_hide_percent_raised {
364 width: 34%;
365 }
366 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary .campaign-summary-item.campaign_hide_amount_donated {
367 width: 43%;
368 }
369 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary .campaign-summary-item.campaign_hide_number_of_donors {
370 width: 23%;
371 }
372 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-preview-campaign-summary .campaign-summary-item.campaign_hide_time_remaining {
373 width: 100%;
374 }
375
376
377 /* field: donate amount */
378
379 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-donate-amount label,
380 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-donate-amount input.custom-donation-input[type="text"] {
381 color: <?php echo $secondary; ?>;
382 border: 1px solid <?php echo $secondary; ?> !important;
383 }
384 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-donate-amount ul li.suggested-donation-amount.selected {
385 background-color: <?php echo $primary; ?>;
386 }
387 <?php echo charitable_esc_attr_php( $wrapper ); ?> .charitable-field-donate-amount ul li.suggested-donation-amount.selected span.amount {
388 color: <?php echo $tertiary; ?>;
389 }
390
391 // @codingStandardsIgnoreEnd