|
115 | 115 | </div> |
116 | 116 | @endif |
117 | 117 |
|
118 | | - {{-- CTA Button --}} |
| 118 | + {{-- Developer Terms Agreement --}} |
119 | 119 | <div class="mt-8"> |
120 | | - <form action="{{ route('customer.developer.onboarding.start') }}" method="POST"> |
| 120 | + <form action="{{ route('customer.developer.onboarding.start') }}" method="POST" x-data="{ termsAccepted: {{ ($developerAccount?->hasAcceptedCurrentTerms()) ? 'true' : 'false' }} }"> |
121 | 121 | @csrf |
| 122 | + |
| 123 | + @if ($developerAccount?->hasAcceptedCurrentTerms()) |
| 124 | + {{-- Already accepted terms, just include hidden field --}} |
| 125 | + <input type="hidden" name="accepted_plugin_terms" value="1" /> |
| 126 | + |
| 127 | + <div class="mb-6 rounded-lg border border-emerald-200 bg-emerald-50 p-4 dark:border-emerald-800 dark:bg-emerald-900/20"> |
| 128 | + <div class="flex items-center gap-3"> |
| 129 | + <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" class="size-5 shrink-0 text-emerald-500"> |
| 130 | + <path stroke-linecap="round" stroke-linejoin="round" d="m4.5 12.75 6 6 9-13.5" /> |
| 131 | + </svg> |
| 132 | + <p class="text-sm text-emerald-800 dark:text-emerald-200"> |
| 133 | + You accepted the <a href="{{ route('developer-terms') }}" class="font-medium underline" target="_blank">Plugin Developer Terms and Conditions</a> on {{ $developerAccount->accepted_plugin_terms_at->format('F j, Y') }}. |
| 134 | + </p> |
| 135 | + </div> |
| 136 | + </div> |
| 137 | + @else |
| 138 | + {{-- Terms acceptance required --}} |
| 139 | + <div class="mb-6 rounded-lg border border-gray-200 bg-gray-50 p-6 dark:border-gray-700 dark:bg-gray-700/50"> |
| 140 | + <h3 class="font-semibold text-gray-900 dark:text-white">Plugin Developer Terms and Conditions</h3> |
| 141 | + <p class="mt-2 text-sm text-gray-600 dark:text-gray-400"> |
| 142 | + Before you can sell plugins on the Marketplace, you must agree to the following key terms: |
| 143 | + </p> |
| 144 | + |
| 145 | + <ul class="mt-4 space-y-3 text-sm text-gray-600 dark:text-gray-400"> |
| 146 | + <li class="flex items-start gap-3"> |
| 147 | + <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="mt-0.5 size-5 shrink-0 text-indigo-500"> |
| 148 | + <path stroke-linecap="round" stroke-linejoin="round" d="M12 6v12m-3-2.818.879.659c1.171.879 3.07.879 4.242 0 1.172-.879 1.172-2.303 0-3.182C13.536 12.219 12.768 12 12 12c-.725 0-1.45-.22-2.003-.659-1.106-.879-1.106-2.303 0-3.182s2.9-.879 4.006 0l.415.33M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z" /> |
| 149 | + </svg> |
| 150 | + <span><strong class="text-gray-900 dark:text-white">30% Platform Fee</strong> — NativePHP retains 30% of each sale to cover payment processing, hosting, and platform maintenance</span> |
| 151 | + </li> |
| 152 | + <li class="flex items-start gap-3"> |
| 153 | + <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="mt-0.5 size-5 shrink-0 text-indigo-500"> |
| 154 | + <path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75 11.25 15 15 9.75m-3-7.036A11.959 11.959 0 0 1 3.598 6 11.99 11.99 0 0 0 3 9.749c0 5.592 3.824 10.29 9 11.623 5.176-1.332 9-6.03 9-11.622 0-1.31-.21-2.571-.598-3.751h-.152c-3.196 0-6.1-1.248-8.25-3.285Z" /> |
| 155 | + </svg> |
| 156 | + <span><strong class="text-gray-900 dark:text-white">Your Responsibility</strong> — You are solely responsible for your plugin's quality, performance, and customer support</span> |
| 157 | + </li> |
| 158 | + <li class="flex items-start gap-3"> |
| 159 | + <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="mt-0.5 size-5 shrink-0 text-indigo-500"> |
| 160 | + <path stroke-linecap="round" stroke-linejoin="round" d="M10.5 6h9.75M10.5 6a1.5 1.5 0 1 1-3 0m3 0a1.5 1.5 0 1 0-3 0M3.75 6H7.5m3 12h9.75m-9.75 0a1.5 1.5 0 0 1-3 0m3 0a1.5 1.5 0 0 0-3 0m-3.75 0H7.5m9-6h3.75m-3.75 0a1.5 1.5 0 0 1-3 0m3 0a1.5 1.5 0 0 0-3 0m-9.75 0h9.75" /> |
| 161 | + </svg> |
| 162 | + <span><strong class="text-gray-900 dark:text-white">Listing Criteria</strong> — NativePHP sets and may change listing standards at any time, and may remove plugins at its discretion</span> |
| 163 | + </li> |
| 164 | + <li class="flex items-start gap-3"> |
| 165 | + <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="mt-0.5 size-5 shrink-0 text-indigo-500"> |
| 166 | + <path stroke-linecap="round" stroke-linejoin="round" d="M9.568 3H5.25A2.25 2.25 0 0 0 3 5.25v4.318c0 .597.237 1.17.659 1.591l9.581 9.581c.699.699 1.78.872 2.607.33a18.095 18.095 0 0 0 5.223-5.223c.542-.827.369-1.908-.33-2.607L11.16 3.66A2.25 2.25 0 0 0 9.568 3Z" /> |
| 167 | + <path stroke-linecap="round" stroke-linejoin="round" d="M6 6h.008v.008H6V6Z" /> |
| 168 | + </svg> |
| 169 | + <span><strong class="text-gray-900 dark:text-white">Pricing & Discounts</strong> — NativePHP sets plugin prices and may offer discounts at its discretion</span> |
| 170 | + </li> |
| 171 | + </ul> |
| 172 | + |
| 173 | + <div class="mt-6 border-t border-gray-200 pt-4 dark:border-gray-600"> |
| 174 | + <label class="flex items-start gap-3 cursor-pointer"> |
| 175 | + <input |
| 176 | + type="checkbox" |
| 177 | + name="accepted_plugin_terms" |
| 178 | + value="1" |
| 179 | + x-model="termsAccepted" |
| 180 | + class="mt-0.5 size-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-500 dark:border-gray-600 dark:bg-gray-700" |
| 181 | + /> |
| 182 | + <span class="text-sm text-gray-700 dark:text-gray-300"> |
| 183 | + I have read and agree to the |
| 184 | + <a href="{{ route('developer-terms') }}" class="font-medium text-indigo-600 underline hover:text-indigo-500 dark:text-indigo-400" target="_blank">Plugin Developer Terms and Conditions</a> |
| 185 | + </span> |
| 186 | + </label> |
| 187 | + @error('accepted_plugin_terms') |
| 188 | + <p class="mt-2 text-sm text-red-600 dark:text-red-400">{{ $message }}</p> |
| 189 | + @enderror |
| 190 | + </div> |
| 191 | + </div> |
| 192 | + @endif |
| 193 | + |
122 | 194 | <button |
123 | 195 | type="submit" |
124 | | - class="w-full rounded-lg bg-indigo-600 px-6 py-3 text-center text-base font-semibold text-white shadow-sm transition hover:bg-indigo-500 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2" |
| 196 | + class="w-full rounded-lg bg-indigo-600 px-6 py-3 text-center text-base font-semibold text-white shadow-sm transition hover:bg-indigo-500 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50" |
| 197 | + :disabled="!termsAccepted" |
125 | 198 | > |
126 | 199 | @if ($hasExistingAccount) |
127 | 200 | Continue Onboarding |
|
0 commit comments