| @@ -1,7 +1,7 @@ | ||
| 1 | 1 | { |
| 2 | 2 | "$schema": "https://schemas.wp.org/trunk/block.json", |
| 3 | - "apiVersion": 1, | |
| 3 | + "apiVersion": 3, | |
| 4 | 4 | "name": "jetpack/donations", |
| 5 | 5 | "title": "Donations Form", |
| 6 | 6 | "description": "Collect one-time, monthly, or annually recurring donations.", |
| 7 | 7 | "keywords": [ |
| @@ -32,11 +32,26 @@ | ||
| 32 | 32 | ], |
| 33 | 33 | "version": "12.5.0", |
| 34 | 34 | "textdomain": "jetpack", |
| 35 | 35 | "category": "monetize", |
| 36 | - "icon": "<svg viewBox='0 0 24 24' width='24' height='24' xmlns='http://www.w3.org/2000/svg'><path d='M16.5 4.5c2.206 0 4 1.794 4 4 0 4.67-5.543 8.94-8.5 11.023C9.043 17.44 3.5 13.17 3.5 8.5c0-2.206 1.794-4 4-4 1.298 0 2.522.638 3.273 1.706L12 7.953l1.227-1.746c.75-1.07 1.975-1.707 3.273-1.707m0-1.5c-1.862 0-3.505.928-4.5 2.344C11.005 3.928 9.362 3 7.5 3 4.462 3 2 5.462 2 8.5c0 5.72 6.5 10.438 10 12.85 3.5-2.412 10-7.13 10-12.85C22 5.462 19.538 3 16.5 3z' /></svg>", | |
| 36 | + "icon": "<svg viewBox='0 0 24 24' width='24' height='24' xmlns='http://www.w3.org/2000/svg'><g transform='translate(1.2 1.2) scale(0.9)'><path d='M16.5 4.5c2.206 0 4 1.794 4 4 0 4.67-5.543 8.94-8.5 11.023C9.043 17.44 3.5 13.17 3.5 8.5c0-2.206 1.794-4 4-4 1.298 0 2.522.638 3.273 1.706L12 7.953l1.227-1.746c.75-1.07 1.975-1.707 3.273-1.707m0-1.5c-1.862 0-3.505.928-4.5 2.344C11.005 3.928 9.362 3 7.5 3 4.462 3 2 5.462 2 8.5c0 5.72 6.5 10.438 10 12.85 3.5-2.412 10-7.13 10-12.85C22 5.462 19.538 3 16.5 3z' /></g></svg>", | |
| 37 | 37 | "supports": { |
| 38 | - "html": false | |
| 38 | + "html": false, | |
| 39 | + "color": { | |
| 40 | + "background": true, | |
| 41 | + "text": true, | |
| 42 | + "button": true, | |
| 43 | + "link": true, | |
| 44 | + "gradients": false | |
| 45 | + }, | |
| 46 | + "typography": { | |
| 47 | + "fontSize": true, | |
| 48 | + "fontFamily": true, | |
| 49 | + "fontStyle": true, | |
| 50 | + "fontWeight": true, | |
| 51 | + "lineHeight": true, | |
| 52 | + "letterSpacing": true | |
| 53 | + } | |
| 39 | 54 | }, |
| 40 | 55 | "attributes": { |
| 41 | 56 | "currency": { |
| 42 | 57 | "type": "string", |
| @@ -50,12 +65,9 @@ | ||
| 50 | 65 | "amounts": [ |
| 51 | 66 | 5, |
| 52 | 67 | 15, |
| 53 | 68 | 100 |
| 54 | - ], | |
| 55 | - "heading": "Make a one-time donation", | |
| 56 | - "extraText": "Your contribution is appreciated.", | |
| 57 | - "buttonText": "Donate" | |
| 69 | + ] | |
| 58 | 70 | } |
| 59 | 71 | }, |
| 60 | 72 | "monthlyDonation": { |
| 61 | 73 | "type": "object", |
| @@ -65,12 +77,9 @@ | ||
| 65 | 77 | "amounts": [ |
| 66 | 78 | 5, |
| 67 | 79 | 15, |
| 68 | 80 | 100 |
| 69 | - ], | |
| 70 | - "heading": "Make a monthly donation", | |
| 71 | - "extraText": "Your contribution is appreciated.", | |
| 72 | - "buttonText": "Donate monthly" | |
| 81 | + ] | |
| 73 | 82 | } |
| 74 | 83 | }, |
| 75 | 84 | "annualDonation": { |
| 76 | 85 | "type": "object", |
| @@ -80,12 +89,9 @@ | ||
| 80 | 89 | "amounts": [ |
| 81 | 90 | 5, |
| 82 | 91 | 15, |
| 83 | 92 | 100 |
| 84 | - ], | |
| 85 | - "heading": "Make a yearly donation", | |
| 86 | - "extraText": "Your contribution is appreciated.", | |
| 87 | - "buttonText": "Donate yearly" | |
| 93 | + ] | |
| 88 | 94 | } |
| 89 | 95 | }, |
| 90 | 96 | "showCustomAmount": { |
| 91 | 97 | "type": "boolean", |
| @@ -90,19 +96,144 @@ | ||
| 90 | 96 | "showCustomAmount": { |
| 91 | 97 | "type": "boolean", |
| 92 | 98 | "default": true |
| 93 | 99 | }, |
| 100 | + "defaultInterval": { | |
| 101 | + "type": "string" | |
| 102 | + }, | |
| 103 | + "customAmountPlaceholder": { | |
| 104 | + "type": "number" | |
| 105 | + }, | |
| 94 | 106 | "chooseAmountText": { |
| 107 | + "type": "string" | |
| 108 | + }, | |
| 109 | + "customAmountText": { | |
| 110 | + "type": "string" | |
| 111 | + }, | |
| 112 | + "fallbackLinkUrl": { | |
| 113 | + "type": "string" | |
| 114 | + }, | |
| 115 | + "activeTabBackgroundColor": { | |
| 116 | + "type": "string" | |
| 117 | + }, | |
| 118 | + "activeTabTextColor": { | |
| 119 | + "type": "string" | |
| 120 | + }, | |
| 121 | + "inactiveTabBackgroundColor": { | |
| 122 | + "type": "string" | |
| 123 | + }, | |
| 124 | + "inactiveTabTextColor": { | |
| 125 | + "type": "string" | |
| 126 | + }, | |
| 127 | + "selectedAmountBackgroundColor": { | |
| 128 | + "type": "string" | |
| 129 | + }, | |
| 130 | + "selectedAmountTextColor": { | |
| 131 | + "type": "string" | |
| 132 | + }, | |
| 133 | + "selectedAmountOutlineColor": { | |
| 134 | + "type": "string" | |
| 135 | + }, | |
| 136 | + "tabsAppearance": { | |
| 95 | 137 | "type": "string", |
| 96 | - "default": "Choose an amount" | |
| 138 | + "enum": [ | |
| 139 | + "tabs", | |
| 140 | + "buttons" | |
| 141 | + ], | |
| 142 | + "default": "tabs" | |
| 97 | 143 | }, |
| 98 | - "customAmountText": { | |
| 144 | + "tabBorderColor": { | |
| 145 | + "type": "string" | |
| 146 | + }, | |
| 147 | + "tabFontSize": { | |
| 148 | + "type": "string" | |
| 149 | + }, | |
| 150 | + "tabPadding": { | |
| 151 | + "type": "object" | |
| 152 | + }, | |
| 153 | + "buttonFontSize": { | |
| 154 | + "type": "string" | |
| 155 | + }, | |
| 156 | + "buttonPadding": { | |
| 157 | + "type": "object" | |
| 158 | + }, | |
| 159 | + "buttonAlignment": { | |
| 99 | 160 | "type": "string", |
| 100 | - "default": "Or enter a custom amount" | |
| 161 | + "enum": [ | |
| 162 | + "", | |
| 163 | + "left", | |
| 164 | + "center", | |
| 165 | + "right", | |
| 166 | + "full" | |
| 167 | + ], | |
| 168 | + "default": "" | |
| 101 | 169 | }, |
| 102 | - "fallbackLinkUrl": { | |
| 170 | + "amountFontSize": { | |
| 103 | 171 | "type": "string" |
| 172 | + }, | |
| 173 | + "amountBorder": { | |
| 174 | + "type": "object" | |
| 175 | + }, | |
| 176 | + "amountBorderRadius": { | |
| 177 | + "type": [ | |
| 178 | + "string", | |
| 179 | + "object" | |
| 180 | + ] | |
| 181 | + }, | |
| 182 | + "buttonBorderRadius": { | |
| 183 | + "type": [ | |
| 184 | + "string", | |
| 185 | + "object" | |
| 186 | + ] | |
| 187 | + }, | |
| 188 | + "contentAlignment": { | |
| 189 | + "type": "string", | |
| 190 | + "enum": [ | |
| 191 | + "", | |
| 192 | + "left", | |
| 193 | + "center", | |
| 194 | + "right" | |
| 195 | + ], | |
| 196 | + "default": "" | |
| 197 | + }, | |
| 198 | + "minimumAmount": { | |
| 199 | + "type": "number" | |
| 200 | + }, | |
| 201 | + "maximumAmount": { | |
| 202 | + "type": "number" | |
| 203 | + }, | |
| 204 | + "displayMode": { | |
| 205 | + "type": "string", | |
| 206 | + "enum": [ | |
| 207 | + "inline", | |
| 208 | + "modal" | |
| 209 | + ], | |
| 210 | + "default": "inline" | |
| 211 | + }, | |
| 212 | + "triggerButtonText": { | |
| 213 | + "type": "string" | |
| 214 | + }, | |
| 215 | + "triggerIcon": { | |
| 216 | + "type": "string", | |
| 217 | + "default": "heart" | |
| 218 | + }, | |
| 219 | + "triggerSticky": { | |
| 220 | + "type": "boolean", | |
| 221 | + "default": false | |
| 222 | + }, | |
| 223 | + "blockBorder": { | |
| 224 | + "type": "object" | |
| 225 | + }, | |
| 226 | + "blockBorderRadius": { | |
| 227 | + "type": [ | |
| 228 | + "string", | |
| 229 | + "object" | |
| 230 | + ] | |
| 231 | + }, | |
| 232 | + "variationName": { | |
| 233 | + "type": "string", | |
| 234 | + "default": "" | |
| 104 | 235 | } |
| 105 | 236 | }, |
| 106 | 237 | "example": {}, |
| 107 | 238 | "editorScript": "jetpack-blocks-editor" |
| 108 | 239 | } |