Skip to content
This repository was archived by the owner on May 12, 2026. It is now read-only.

Commit fe42c88

Browse files
committed
rate limits layut
1 parent f730e79 commit fe42c88

1 file changed

Lines changed: 47 additions & 47 deletions

File tree

  • src/routes/(protected)/consumers/[consumer_id]/rate-limits

‎src/routes/(protected)/consumers/[consumer_id]/rate-limits/+page.svelte‎

Lines changed: 47 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,53 @@
143143
</a>
144144
</div>
145145

146+
<!-- Consumer Header -->
147+
<div class="mb-6">
148+
<div class="flex items-start justify-between">
149+
<div>
150+
<h1 class="text-3xl font-bold text-gray-900 dark:text-gray-100 mb-2">
151+
Rate Limits: {consumer.app_name}
152+
</h1>
153+
<p class="mt-1 text-sm text-gray-600 dark:text-gray-400">
154+
Consumer ID: <code
155+
class="rounded bg-gray-100 px-2 py-0.5 text-xs dark:bg-gray-900"
156+
>{consumer.consumer_id}</code
157+
>
158+
</p>
159+
</div>
160+
<div class="flex items-center gap-2">
161+
<span
162+
class="rounded-full px-3 py-1 text-xs font-medium {consumer.enabled
163+
? 'bg-green-100 text-green-800 dark:bg-green-900/30 dark:text-green-400'
164+
: 'bg-red-100 text-red-800 dark:bg-red-900/30 dark:text-red-400'}"
165+
>
166+
{consumer.enabled ? "Enabled" : "Disabled"}
167+
</span>
168+
<span
169+
class="rounded-full px-3 py-1 text-xs font-medium bg-blue-100 text-blue-800 dark:bg-blue-900/30 dark:text-blue-400"
170+
>
171+
{consumer.app_type}
172+
</span>
173+
</div>
174+
</div>
175+
176+
<!-- Caching Information -->
177+
<div class="mt-4 text-sm text-gray-600 dark:text-gray-400">
178+
<svg
179+
class="inline-block mr-1 h-4 w-4"
180+
fill="currentColor"
181+
viewBox="0 0 20 20"
182+
>
183+
<path
184+
fill-rule="evenodd"
185+
d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z"
186+
clip-rule="evenodd"
187+
/>
188+
</svg>
189+
Note: Rate limit records and active rate limits are cached for up to an hour.
190+
</div>
191+
</div>
192+
146193
<!-- Rate Limiting System Status -->
147194
{#if rateLimitingInfo}
148195
<div
@@ -215,53 +262,6 @@
215262
</div>
216263
{/if}
217264

218-
<!-- Consumer Header -->
219-
<div class="mb-6">
220-
<div class="flex items-start justify-between">
221-
<div>
222-
<h1 class="text-3xl font-bold text-gray-900 dark:text-gray-100 mb-2">
223-
Rate Limits: {consumer.app_name}
224-
</h1>
225-
<p class="mt-1 text-sm text-gray-600 dark:text-gray-400">
226-
Consumer ID: <code
227-
class="rounded bg-gray-100 px-2 py-0.5 text-xs dark:bg-gray-900"
228-
>{consumer.consumer_id}</code
229-
>
230-
</p>
231-
</div>
232-
<div class="flex items-center gap-2">
233-
<span
234-
class="rounded-full px-3 py-1 text-xs font-medium {consumer.enabled
235-
? 'bg-green-100 text-green-800 dark:bg-green-900/30 dark:text-green-400'
236-
: 'bg-red-100 text-red-800 dark:bg-red-900/30 dark:text-red-400'}"
237-
>
238-
{consumer.enabled ? "Enabled" : "Disabled"}
239-
</span>
240-
<span
241-
class="rounded-full px-3 py-1 text-xs font-medium bg-blue-100 text-blue-800 dark:bg-blue-900/30 dark:text-blue-400"
242-
>
243-
{consumer.app_type}
244-
</span>
245-
</div>
246-
</div>
247-
248-
<!-- Caching Information -->
249-
<div class="mt-4 text-sm text-gray-600 dark:text-gray-400">
250-
<svg
251-
class="inline-block mr-1 h-4 w-4"
252-
fill="currentColor"
253-
viewBox="0 0 20 20"
254-
>
255-
<path
256-
fill-rule="evenodd"
257-
d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z"
258-
clip-rule="evenodd"
259-
/>
260-
</svg>
261-
Note: Rate limit records and active rate limits are cached for up to an hour.
262-
</div>
263-
</div>
264-
265265
<!-- Current Usage Card -->
266266
<div
267267
class="mb-6 rounded-lg border border-blue-200 bg-blue-50 p-6 dark:border-blue-700 dark:bg-blue-900/20"

0 commit comments

Comments
 (0)