@stacksjs/defaults 0.70.54
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +21 -0
- package/README.md +2 -0
- package/package.json +20 -0
- package/resources/assets/fonts/013717e9.woff +0 -0
- package/resources/assets/fonts/03355817.woff2 +0 -0
- package/resources/assets/fonts/0380de7e.woff2 +0 -0
- package/resources/assets/fonts/0ba5d32a.woff +0 -0
- package/resources/assets/fonts/0bd57ddf.woff2 +0 -0
- package/resources/assets/fonts/19de0a60.woff2 +0 -0
- package/resources/assets/fonts/20b87e84.woff +0 -0
- package/resources/assets/fonts/4bbc67e1.woff +0 -0
- package/resources/assets/fonts/576fb0d7.woff +0 -0
- package/resources/assets/fonts/5ea10ee5.woff2 +0 -0
- package/resources/assets/fonts/6413fc0a.woff +0 -0
- package/resources/assets/fonts/72c114cf.woff +0 -0
- package/resources/assets/fonts/73c57e73.woff2 +0 -0
- package/resources/assets/fonts/813dca6c.woff +0 -0
- package/resources/assets/fonts/8a9b0995.woff2 +0 -0
- package/resources/assets/fonts/90b4832f.woff +0 -0
- package/resources/assets/fonts/9394ab85.woff2 +0 -0
- package/resources/assets/fonts/9b3c7d7f.woff2 +0 -0
- package/resources/assets/fonts/Monaco.ttf +0 -0
- package/resources/assets/fonts/b1b36d74.woff +0 -0
- package/resources/assets/fonts/b5d74798.woff2 +0 -0
- package/resources/assets/fonts/b9f81a4d.woff +0 -0
- package/resources/assets/fonts/c9784008.woff2 +0 -0
- package/resources/assets/fonts/cf692227.woff +0 -0
- package/resources/assets/fonts/d1c6ab51.woff2 +0 -0
- package/resources/assets/fonts/e2eb62fc.woff +0 -0
- package/resources/assets/fonts/fe21f8d8.woff2 +0 -0
- package/resources/assets/fonts/nps/CampmateScript-Regular.woff2 +0 -0
- package/resources/assets/fonts/nps/NPS_2026-variable.woff2 +0 -0
- package/resources/assets/fonts/nps/RedwoodSerif-Regular.woff2 +0 -0
- package/resources/assets/fonts/nps/SequoiaSans-Regular.woff2 +0 -0
- package/resources/assets/fonts/nps/Switchback-Regular.woff2 +0 -0
- package/resources/assets/images/app-icon.png +0 -0
- package/resources/assets/images/bg-img.png +0 -0
- package/resources/assets/images/park-ridge.svg +15 -0
- package/resources/assets/images/topography.svg +1 -0
- package/resources/assets/scripts/main.ts +2153 -0
- package/resources/assets/styles/README.md +19 -0
- package/resources/assets/styles/docs/main.css +1 -0
- package/resources/assets/styles/docs/overrides.css +1 -0
- package/resources/assets/styles/docs/vars.css +8 -0
- package/resources/assets/styles/main.css +1419 -0
- package/resources/components/Button.stx +70 -0
- package/resources/components/Buttons/BaseButton.stx +39 -0
- package/resources/components/Buttons/Counter.stx +28 -0
- package/resources/components/Buttons/ToggleDark.stx +11 -0
- package/resources/components/Container.stx +10 -0
- package/resources/components/Dashboard/.gitkeep +0 -0
- package/resources/components/Dashboard/Auth/ForgotPassword.stx +127 -0
- package/resources/components/Dashboard/Auth/Login.stx +212 -0
- package/resources/components/Dashboard/Auth/Register.stx +306 -0
- package/resources/components/Dashboard/Avatar.stx +123 -0
- package/resources/components/Dashboard/Billing/ActivePlan.stx +57 -0
- package/resources/components/Dashboard/Billing/CardBrands.stx +32 -0
- package/resources/components/Dashboard/Billing/CardForm.stx +34 -0
- package/resources/components/Dashboard/Billing/OneTimePayment.stx +28 -0
- package/resources/components/Dashboard/Billing/PaymentForm.stx +33 -0
- package/resources/components/Dashboard/Billing/PaymentMethod.stx +66 -0
- package/resources/components/Dashboard/Billing/PaymentMethodList.stx +52 -0
- package/resources/components/Dashboard/Billing/Plans.stx +136 -0
- package/resources/components/Dashboard/Buttons/AppButton.stx +48 -0
- package/resources/components/Dashboard/Buttons/IconButton.stx +20 -0
- package/resources/components/Dashboard/Card.stx +78 -0
- package/resources/components/Dashboard/Chart.stx +75 -0
- package/resources/components/Dashboard/CodeEditor.stx +41 -0
- package/resources/components/Dashboard/Commerce/BulkActionBar.stx +70 -0
- package/resources/components/Dashboard/Commerce/CategoriesTable.stx +133 -0
- package/resources/components/Dashboard/Commerce/CouponsTable.stx +161 -0
- package/resources/components/Dashboard/Commerce/CustomersTable.stx +142 -0
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryRoutesTable.stx +80 -0
- package/resources/components/Dashboard/Commerce/Delivery/DigitalDeliveryTable.stx +85 -0
- package/resources/components/Dashboard/Commerce/Delivery/DriversTable.stx +99 -0
- package/resources/components/Dashboard/Commerce/Delivery/LicenseKeysTable.stx +92 -0
- package/resources/components/Dashboard/Commerce/Delivery/LicenseTemplatesTable.stx +88 -0
- package/resources/components/Dashboard/Commerce/Delivery/Pagination.stx +122 -0
- package/resources/components/Dashboard/Commerce/Delivery/SearchFilter.stx +23 -0
- package/resources/components/Dashboard/Commerce/Delivery/ShippingMethodsTable.stx +80 -0
- package/resources/components/Dashboard/Commerce/Delivery/ShippingRatesTable.stx +59 -0
- package/resources/components/Dashboard/Commerce/Delivery/ShippingZonesTable.stx +71 -0
- package/resources/components/Dashboard/Commerce/Delivery/TabNavigation.stx +36 -0
- package/resources/components/Dashboard/Commerce/Forms/CouponsForm.stx +191 -0
- package/resources/components/Dashboard/Commerce/OrdersTable.stx +131 -0
- package/resources/components/Dashboard/Commerce/ProductsTable.stx +170 -0
- package/resources/components/Dashboard/CreateRecordModal.stx +363 -0
- package/resources/components/Dashboard/DashboardLayout.stx +155 -0
- package/resources/components/Dashboard/Deployments/ActivityFeed.stx +54 -0
- package/resources/components/Dashboard/Deployments/DeployScript.stx +23 -0
- package/resources/components/Dashboard/Deployments/DeploymentHistory.stx +97 -0
- package/resources/components/Dashboard/Deployments/DeploymentList.stx +94 -0
- package/resources/components/Dashboard/Deployments/LiveTerminalOutput.stx +18 -0
- package/resources/components/Dashboard/Elements/Dropdown.stx +57 -0
- package/resources/components/Dashboard/Email/EmailActivityChart.stx +111 -0
- package/resources/components/Dashboard/Email/EmailCompose.stx +72 -0
- package/resources/components/Dashboard/Email/EmailDetail.stx +105 -0
- package/resources/components/Dashboard/Email/EmailList.stx +117 -0
- package/resources/components/Dashboard/Email/EmailSearch.stx +40 -0
- package/resources/components/Dashboard/Email/EmailSidebar.stx +133 -0
- package/resources/components/Dashboard/GlobalSearch.stx +124 -0
- package/resources/components/Dashboard/MobileSidebar.stx +47 -0
- package/resources/components/Dashboard/Modals/BaseModal.stx +50 -0
- package/resources/components/Dashboard/Modals/Popups/Alert.stx +112 -0
- package/resources/components/Dashboard/Modals/Popups/Toast.stx +70 -0
- package/resources/components/Dashboard/Modals/ToastWrapper.stx +35 -0
- package/resources/components/Dashboard/Monitoring/ErrorDetailModal.stx +228 -0
- package/resources/components/Dashboard/Monitoring/ErrorsTable.stx +184 -0
- package/resources/components/Dashboard/Navbar.stx +194 -0
- package/resources/components/Dashboard/NavbarModern.stx +188 -0
- package/resources/components/Dashboard/NotificationErrorModal.stx +105 -0
- package/resources/components/Dashboard/NotificationStatusBadge.stx +20 -0
- package/resources/components/Dashboard/Pagination.stx +90 -0
- package/resources/components/Dashboard/Queue/QueueTable.stx +127 -0
- package/resources/components/Dashboard/Settings/Forms/AIForm.stx +126 -0
- package/resources/components/Dashboard/Settings/Forms/AnalyticsForm.stx +52 -0
- package/resources/components/Dashboard/Settings/Forms/AppForm.stx +157 -0
- package/resources/components/Dashboard/Settings/Forms/CLIForm.stx +66 -0
- package/resources/components/Dashboard/Settings/Forms/CacheForm.stx +253 -0
- package/resources/components/Dashboard/Settings/Forms/CloudForm.stx +441 -0
- package/resources/components/Dashboard/Settings/Forms/DNSForm.stx +307 -0
- package/resources/components/Dashboard/Settings/Forms/DatabaseForm.stx +168 -0
- package/resources/components/Dashboard/Settings/Forms/EmailForm.stx +100 -0
- package/resources/components/Dashboard/Settings/Forms/FileSystemForm.stx +259 -0
- package/resources/components/Dashboard/Settings/Forms/HashingForm.stx +119 -0
- package/resources/components/Dashboard/Settings/Forms/LibraryForm.stx +389 -0
- package/resources/components/Dashboard/Settings/Forms/QueueForm.stx +219 -0
- package/resources/components/Dashboard/Settings/Forms/SearchEngineForm.stx +48 -0
- package/resources/components/Dashboard/Settings/Forms/SecurityForm.stx +143 -0
- package/resources/components/Dashboard/Settings/Forms/ServicesForm.stx +194 -0
- package/resources/components/Dashboard/Settings/Forms/StorageForm.stx +191 -0
- package/resources/components/Dashboard/Settings/Forms/TeamsForm.stx +33 -0
- package/resources/components/Dashboard/Settings/SettingsFormManager.stx +181 -0
- package/resources/components/Dashboard/SettingsHeader.stx +88 -0
- package/resources/components/Dashboard/SettingsSidebar.stx +234 -0
- package/resources/components/Dashboard/Sidebar.stx +23 -0
- package/resources/components/Dashboard/SidebarModern.stx +249 -0
- package/resources/components/Dashboard/Skeleton/LoadingCard.stx +15 -0
- package/resources/components/Dashboard/Skeleton/LoadingDetails.stx +26 -0
- package/resources/components/Dashboard/Table.stx +82 -0
- package/resources/components/Dashboard/TerminalContainer.stx +97 -0
- package/resources/components/Dashboard/Tooltip.stx +166 -0
- package/resources/components/Dashboard/Transaction/index.stx +88 -0
- package/resources/components/Dashboard/UI/ActivityTable.stx +54 -0
- package/resources/components/Dashboard/UI/Avatar.stx +102 -0
- package/resources/components/Dashboard/UI/Badge.stx +66 -0
- package/resources/components/Dashboard/UI/Button.stx +73 -0
- package/resources/components/Dashboard/UI/Card.stx +51 -0
- package/resources/components/Dashboard/UI/ChartCard.stx +36 -0
- package/resources/components/Dashboard/UI/Checkbox.stx +74 -0
- package/resources/components/Dashboard/UI/ConfirmDialog.stx +74 -0
- package/resources/components/Dashboard/UI/DataTable.stx +45 -0
- package/resources/components/Dashboard/UI/Dropdown.stx +72 -0
- package/resources/components/Dashboard/UI/DropdownItem.stx +80 -0
- package/resources/components/Dashboard/UI/EmptyState.stx +50 -0
- package/resources/components/Dashboard/UI/FilterBar.stx +48 -0
- package/resources/components/Dashboard/UI/Input.stx +77 -0
- package/resources/components/Dashboard/UI/Modal.stx +75 -0
- package/resources/components/Dashboard/UI/PageHeader.stx +69 -0
- package/resources/components/Dashboard/UI/PageLayout.stx +84 -0
- package/resources/components/Dashboard/UI/Pagination.stx +126 -0
- package/resources/components/Dashboard/UI/QuickLinks.stx +31 -0
- package/resources/components/Dashboard/UI/RouterLink.stx +31 -0
- package/resources/components/Dashboard/UI/Select.stx +84 -0
- package/resources/components/Dashboard/UI/ServiceHealth.stx +38 -0
- package/resources/components/Dashboard/UI/StatsCard.stx +79 -0
- package/resources/components/Dashboard/UI/Table.stx +143 -0
- package/resources/components/Dashboard/UI/Tabs.stx +45 -0
- package/resources/components/Dashboard/UI/Textarea.stx +93 -0
- package/resources/components/Dashboard/UI/Toggle.stx +84 -0
- package/resources/components/Dashboard/UI/WindowControls.stx +135 -0
- package/resources/components/Dashboard/Widget.stx +89 -0
- package/resources/components/Dashboard/WindowControls.stx +119 -0
- package/resources/components/Dashboard/index.ts +106 -0
- package/resources/components/Docs/Demo/ComboboxCode.md +114 -0
- package/resources/components/Docs/Demo/ComboboxDemo.stx +91 -0
- package/resources/components/Docs/Demo/DialogCode.md +42 -0
- package/resources/components/Docs/Demo/DialogDemo.stx +76 -0
- package/resources/components/Docs/Demo/DocsPlayground.stx +39 -0
- package/resources/components/Docs/Demo/DropdownCode.md +109 -0
- package/resources/components/Docs/Demo/DropdownDemo.stx +82 -0
- package/resources/components/Docs/Demo/Hero.stx +100 -0
- package/resources/components/Docs/Demo/ListboxCode.md +87 -0
- package/resources/components/Docs/Demo/ListboxDemo.stx +59 -0
- package/resources/components/Docs/Demo/NotificationCode.md +173 -0
- package/resources/components/Docs/Demo/NotificationDemo.stx +99 -0
- package/resources/components/Docs/Demo/PopoverCode.md +161 -0
- package/resources/components/Docs/Demo/PopoverDemo.stx +96 -0
- package/resources/components/Docs/Demo/RadioGroupCode.md +98 -0
- package/resources/components/Docs/Demo/RadioGroupDemo.stx +53 -0
- package/resources/components/Docs/Demo/StepperCode.md +216 -0
- package/resources/components/Docs/Demo/StepperDemo.stx +137 -0
- package/resources/components/Docs/Demo/SwitchCode.md +24 -0
- package/resources/components/Docs/Demo/SwitchDemo.stx +28 -0
- package/resources/components/Docs/Home.stx +7 -0
- package/resources/components/Docs/HomeContributors.stx +23 -0
- package/resources/components/Docs/HomeSponsors.stx +17 -0
- package/resources/components/Docs/HomeTeam.stx +18 -0
- package/resources/components/Docs/TeamMember.stx +79 -0
- package/resources/components/Email/EmailButton.stx +32 -0
- package/resources/components/Email/EmailDivider.stx +20 -0
- package/resources/components/Email/EmailImage.stx +24 -0
- package/resources/components/Email/EmailLayout.stx +55 -0
- package/resources/components/Email/EmailLink.stx +22 -0
- package/resources/components/Email/EmailSection.stx +20 -0
- package/resources/components/Email/EmailText.stx +30 -0
- package/resources/components/Forum/ForumBreadcrumb.stx +38 -0
- package/resources/components/Forum/ForumCategory.stx +16 -0
- package/resources/components/Forum/ForumCategoryItem.stx +46 -0
- package/resources/components/Forum/ForumLayout.stx +36 -0
- package/resources/components/Forum/ForumPagination.stx +39 -0
- package/resources/components/Forum/ForumPost.stx +71 -0
- package/resources/components/Forum/ForumReplyForm.stx +76 -0
- package/resources/components/Forum/ForumSidebar.stx +86 -0
- package/resources/components/Forum/ForumTopicItem.stx +77 -0
- package/resources/components/Forum/ForumTopicList.stx +23 -0
- package/resources/components/HelloWorld.stx +253 -0
- package/resources/components/Logo.stx +10 -0
- package/resources/components/Marketing/CallToAction.stx +30 -0
- package/resources/components/Marketing/ComingSoon.stx +155 -0
- package/resources/components/Marketing/Faqs.stx +99 -0
- package/resources/components/Marketing/Feature.stx +32 -0
- package/resources/components/Marketing/Fields.stx +28 -0
- package/resources/components/Marketing/Footer.stx +33 -0
- package/resources/components/Marketing/Header.stx +51 -0
- package/resources/components/Marketing/Hero.stx +46 -0
- package/resources/components/Marketing/Layout.stx +26 -0
- package/resources/components/Marketing/NavLink.stx +13 -0
- package/resources/components/Marketing/Plan.stx +43 -0
- package/resources/components/Marketing/Pricing.stx +120 -0
- package/resources/components/Marketing/PrimaryFeatures.stx +80 -0
- package/resources/components/Marketing/PrimaryFeatures2.stx +98 -0
- package/resources/components/Marketing/SecondaryFeatures.stx +80 -0
- package/resources/components/Marketing/Testimonials.stx +120 -0
- package/resources/components/Pagination.stx +149 -0
- package/resources/components/Playground.stx +9 -0
- package/resources/components/README.md +87 -0
- package/resources/components/Storefront/AnnouncementBar.stx +17 -0
- package/resources/components/Storefront/CartDrawer.stx +227 -0
- package/resources/components/Storefront/CheckoutSteps.stx +50 -0
- package/resources/components/Storefront/Footer.stx +81 -0
- package/resources/components/Storefront/Header.stx +66 -0
- package/resources/components/Storefront/OrderSummary.stx +79 -0
- package/resources/components/Storefront/ProductCard.stx +63 -0
- package/resources/components/Storefront/ProductGallery.stx +88 -0
- package/resources/components/Storefront/QuantitySelector.stx +97 -0
- package/resources/components/index.ts +13 -0
- package/resources/emails/email-verification.stx +46 -0
- package/resources/emails/layouts/base.html +113 -0
- package/resources/emails/password-changed.stx +55 -0
- package/resources/emails/password-reset.stx +43 -0
- package/resources/emails/subscription-confirmation.stx +99 -0
- package/resources/emails/welcome.stx +48 -0
- package/resources/functions/README.md +28 -0
- package/resources/functions/counter.ts +13 -0
- package/resources/functions/dark.ts +4 -0
- package/resources/functions/dashboard/analytics.ts +238 -0
- package/resources/functions/dashboard/config-io.ts +316 -0
- package/resources/functions/dashboard/data.ts +375 -0
- package/resources/functions/dashboard/library.ts +250 -0
- package/resources/functions/dashboard/sidebar.ts +537 -0
- package/resources/functions/dashboard/system.ts +150 -0
- package/resources/layouts/403.stx +188 -0
- package/resources/layouts/404.stx +34 -0
- package/resources/layouts/README.md +14 -0
- package/resources/layouts/dashboard/default.stx +20 -0
- package/resources/layouts/dashboard/guest.stx +10 -0
- package/resources/layouts/default.stx +3 -0
- package/resources/layouts/maintenance.stx +11 -0
- package/resources/layouts/storefront.stx +73 -0
- package/resources/layouts/system-tray/default.stx +3 -0
- package/resources/modules/.gitkeep +0 -0
- package/resources/plugins/.gitkeep +0 -0
- package/resources/plugins/preloader.ts +308 -0
- package/resources/types/README.md +3 -0
- package/resources/views/cart.stx +149 -0
- package/resources/views/checkout/contact.stx +101 -0
- package/resources/views/checkout/payment.stx +114 -0
- package/resources/views/checkout/shipping.stx +120 -0
- package/resources/views/coming-soon.stx +9 -0
- package/resources/views/dashboard/custom-page.stx +45 -0
- package/resources/views/dashboard/index.stx +24 -0
- package/resources/views/emails/welcome.stx +0 -0
- package/resources/views/errors/tester.stx +26 -0
- package/resources/views/index.stx +2865 -0
- package/resources/views/orders/[id].stx +130 -0
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface LicenseKeysTableProps {
|
|
3
|
+
licenseKeys?: any[]
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const { licenseKeys = [] } = defineProps<LicenseKeysTableProps>()
|
|
7
|
+
|
|
8
|
+
function statusVariant(status) {
|
|
9
|
+
const s = String(status || '').toLowerCase()
|
|
10
|
+
if (s === 'active') return 'success'
|
|
11
|
+
if (s === 'expired') return 'warning'
|
|
12
|
+
if (s === 'revoked') return 'danger'
|
|
13
|
+
return 'default'
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
function uppercaseFirstLetter(status) {
|
|
17
|
+
return status.charAt(0).toUpperCase() + status.slice(1)
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function formatDate(date) {
|
|
21
|
+
if (!date) return 'N/A'
|
|
22
|
+
return new Date(date).toLocaleDateString()
|
|
23
|
+
}
|
|
24
|
+
</script>
|
|
25
|
+
<div class="overflow-hidden border border-stone-200/80 rounded-xl dark:border-neutral-700 shadow-sm">
|
|
26
|
+
<table class="min-w-full divide-stone-100 divide-y dark:divide-neutral-700">
|
|
27
|
+
<thead class="bg-stone-50/80 dark:bg-neutral-800">
|
|
28
|
+
<tr>
|
|
29
|
+
<th scope="col" class="pl-6 pr-3 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Key</th>
|
|
30
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Template</th>
|
|
31
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Customer</th>
|
|
32
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Product</th>
|
|
33
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Order ID</th>
|
|
34
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Date Created</th>
|
|
35
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Expiry Date</th>
|
|
36
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Status</th>
|
|
37
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Actions</th>
|
|
38
|
+
</tr>
|
|
39
|
+
</thead>
|
|
40
|
+
<tbody class="bg-white dark:bg-neutral-800 divide-stone-100 divide-y dark:divide-neutral-700">
|
|
41
|
+
@foreach(licenseKeys as licenseKey)
|
|
42
|
+
<tr class="hover:bg-stone-50/50 dark:hover:bg-neutral-700/50 transition-colors">
|
|
43
|
+
<td class="pl-6 pr-3 py-3.5 font-medium text-sm text-stone-800 whitespace-nowrap dark:text-white">
|
|
44
|
+
{{ licenseKey.key }}
|
|
45
|
+
</td>
|
|
46
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
47
|
+
{{ licenseKey.template }}
|
|
48
|
+
</td>
|
|
49
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
50
|
+
{{ licenseKey.customer.name }}
|
|
51
|
+
<div class="text-stone-400 text-xs dark:text-neutral-500">{{ licenseKey.customer.email }}</div>
|
|
52
|
+
</td>
|
|
53
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
54
|
+
{{ licenseKey.product }}
|
|
55
|
+
</td>
|
|
56
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
57
|
+
{{ licenseKey.order_id }}
|
|
58
|
+
</td>
|
|
59
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
60
|
+
{{ formatDate(licenseKey.created_at) }}
|
|
61
|
+
</td>
|
|
62
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
63
|
+
{{ formatDate(licenseKey.expiry_date) }}
|
|
64
|
+
</td>
|
|
65
|
+
<td class="px-4 py-3.5 text-sm whitespace-nowrap">
|
|
66
|
+
<Badge variant="{{ statusVariant(licenseKey.status) }}" size="sm">
|
|
67
|
+
{{ uppercaseFirstLetter(licenseKey.status) }}
|
|
68
|
+
</Badge>
|
|
69
|
+
</td>
|
|
70
|
+
<td class="relative pl-3 pr-6 py-3.5 font-medium text-right text-sm whitespace-nowrap">
|
|
71
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" data-action="view" data-license-id="{{ licenseKey.id }}" title="View">
|
|
72
|
+
<div class="h-5 w-5 i-hugeicons-view"></div>
|
|
73
|
+
</button>
|
|
74
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" data-action="edit" data-license-id="{{ licenseKey.id }}" title="Edit">
|
|
75
|
+
<div class="h-5 w-5 i-hugeicons-edit-01"></div>
|
|
76
|
+
</button>
|
|
77
|
+
<button type="button" class="p-2 text-stone-400 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300 border border-transparent rounded-md hover:border-red-200 dark:hover:border-red-800 duration-150 transition-colors" data-action="delete" data-license-id="{{ licenseKey.id }}" title="Delete">
|
|
78
|
+
<div class="h-5 w-5 i-hugeicons-waste"></div>
|
|
79
|
+
</button>
|
|
80
|
+
</td>
|
|
81
|
+
</tr>
|
|
82
|
+
@endforeach
|
|
83
|
+
@if(licenseKeys.length == 0)
|
|
84
|
+
<tr>
|
|
85
|
+
<td colspan="9" class="px-6 py-3.5 text-center text-sm text-stone-500 dark:text-neutral-400">
|
|
86
|
+
No license keys found
|
|
87
|
+
</td>
|
|
88
|
+
</tr>
|
|
89
|
+
@endif
|
|
90
|
+
</tbody>
|
|
91
|
+
</table>
|
|
92
|
+
</div>
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface LicenseTemplatesTableProps {
|
|
3
|
+
templates?: any[]
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const { templates = [] } = defineProps<LicenseTemplatesTableProps>()
|
|
7
|
+
|
|
8
|
+
function statusVariant(active, status) {
|
|
9
|
+
if (status) {
|
|
10
|
+
const s = String(Array.isArray(status) ? status[0] || '' : status).toLowerCase()
|
|
11
|
+
if (s === 'active') return 'success'
|
|
12
|
+
return 'default'
|
|
13
|
+
}
|
|
14
|
+
return active ? 'success' : 'default'
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
function getStatusText(active, status) {
|
|
18
|
+
if (status) {
|
|
19
|
+
const statusStr = Array.isArray(status) ? (status.length > 0 ? status[0] : undefined) : status
|
|
20
|
+
if (statusStr) {
|
|
21
|
+
return statusStr.charAt(0).toUpperCase() + statusStr.slice(1)
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
return active ? 'Active' : 'Inactive'
|
|
26
|
+
}
|
|
27
|
+
</script>
|
|
28
|
+
<div class="overflow-hidden border border-stone-200/80 rounded-xl dark:border-neutral-700 shadow-sm">
|
|
29
|
+
<table class="min-w-full divide-stone-100 divide-y dark:divide-neutral-700">
|
|
30
|
+
<thead class="bg-stone-50/80 dark:bg-neutral-800">
|
|
31
|
+
<tr>
|
|
32
|
+
<th scope="col" class="pl-6 pr-3 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Name</th>
|
|
33
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Format</th>
|
|
34
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Prefix</th>
|
|
35
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Segments</th>
|
|
36
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Character Set</th>
|
|
37
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Status</th>
|
|
38
|
+
<th scope="col" class="relative pl-3 pr-6 py-3.5">
|
|
39
|
+
<span class="sr-only">Actions</span>
|
|
40
|
+
</th>
|
|
41
|
+
</tr>
|
|
42
|
+
</thead>
|
|
43
|
+
<tbody class="bg-white dark:bg-neutral-800 divide-stone-100 divide-y dark:divide-neutral-700">
|
|
44
|
+
@foreach(templates as template)
|
|
45
|
+
<tr class="hover:bg-stone-50/50 dark:hover:bg-neutral-700/50 transition-colors">
|
|
46
|
+
<td class="pl-6 pr-3 py-3.5 font-medium text-sm text-stone-800 whitespace-nowrap dark:text-white">
|
|
47
|
+
{{ template.name }}
|
|
48
|
+
</td>
|
|
49
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
50
|
+
{{ template.format }}
|
|
51
|
+
</td>
|
|
52
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
53
|
+
{{ template.prefix || 'None' }}
|
|
54
|
+
</td>
|
|
55
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
56
|
+
{{ template.segment_count }} x {{ template.segment_length }}
|
|
57
|
+
</td>
|
|
58
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
59
|
+
{{ template.char_set.length }} chars
|
|
60
|
+
</td>
|
|
61
|
+
<td class="px-4 py-3.5 text-sm whitespace-nowrap">
|
|
62
|
+
<Badge variant="{{ statusVariant(template.active, template.status) }}" size="sm">
|
|
63
|
+
{{ getStatusText(template.active, template.status) }}
|
|
64
|
+
</Badge>
|
|
65
|
+
</td>
|
|
66
|
+
<td class="relative pl-3 pr-6 py-3.5 font-medium text-right text-sm whitespace-nowrap">
|
|
67
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" data-action="view" data-template-id="{{ template.id }}" title="View">
|
|
68
|
+
<div class="h-5 w-5 i-hugeicons-view"></div>
|
|
69
|
+
</button>
|
|
70
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" data-action="edit" data-template-id="{{ template.id }}" title="Edit">
|
|
71
|
+
<div class="h-5 w-5 i-hugeicons-edit-01"></div>
|
|
72
|
+
</button>
|
|
73
|
+
<button type="button" class="p-2 text-stone-400 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300 border border-transparent rounded-md hover:border-red-200 dark:hover:border-red-800 duration-150 transition-colors" data-action="delete" data-template-id="{{ template.id }}" title="Delete">
|
|
74
|
+
<div class="h-5 w-5 i-hugeicons-waste"></div>
|
|
75
|
+
</button>
|
|
76
|
+
</td>
|
|
77
|
+
</tr>
|
|
78
|
+
@endforeach
|
|
79
|
+
@if(templates.length == 0)
|
|
80
|
+
<tr>
|
|
81
|
+
<td colspan="7" class="px-6 py-3.5 text-center text-sm text-stone-500 dark:text-neutral-400">
|
|
82
|
+
No license templates found
|
|
83
|
+
</td>
|
|
84
|
+
</tr>
|
|
85
|
+
@endif
|
|
86
|
+
</tbody>
|
|
87
|
+
</table>
|
|
88
|
+
</div>
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface PaginationProps {
|
|
3
|
+
currentPage?: number
|
|
4
|
+
totalItems?: number
|
|
5
|
+
itemsPerPage?: number
|
|
6
|
+
maxDisplayedPages?: number
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
const { currentPage = 1, totalItems = 0, itemsPerPage = 10, maxDisplayedPages = 5 } = defineProps<PaginationProps>()
|
|
10
|
+
|
|
11
|
+
const totalPages = Math.ceil(totalItems / itemsPerPage)
|
|
12
|
+
const startItem = ((currentPage - 1) * itemsPerPage) + 1
|
|
13
|
+
const endItem = Math.min(currentPage * itemsPerPage, totalItems)
|
|
14
|
+
|
|
15
|
+
function getDisplayedPages() {
|
|
16
|
+
if (totalPages <= maxDisplayedPages) {
|
|
17
|
+
return Array.from({ length: totalPages }, (_, i) => i + 1)
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const pages = []
|
|
21
|
+
const halfMax = Math.floor(maxDisplayedPages / 2)
|
|
22
|
+
|
|
23
|
+
// Always show first page
|
|
24
|
+
pages.push(1)
|
|
25
|
+
|
|
26
|
+
// Add ellipsis if needed
|
|
27
|
+
if (currentPage - halfMax > 2) {
|
|
28
|
+
pages.push('...')
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
// Add pages around current page
|
|
32
|
+
const start = Math.max(2, currentPage - halfMax)
|
|
33
|
+
const end = Math.min(totalPages - 1, currentPage + halfMax)
|
|
34
|
+
|
|
35
|
+
for (let i = start; i <= end; i++) {
|
|
36
|
+
pages.push(i)
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
// Add ellipsis if needed
|
|
40
|
+
if (currentPage + halfMax < totalPages - 1) {
|
|
41
|
+
pages.push('...')
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// Always show last page
|
|
45
|
+
if (totalPages > 1) {
|
|
46
|
+
pages.push(totalPages)
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
return pages
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
const displayedPages = getDisplayedPages()
|
|
53
|
+
</script>
|
|
54
|
+
<div class="flex items-center justify-between mt-5 px-4 py-3 sm:px-6 border-gray-200 border-t dark:border-neutral-700">
|
|
55
|
+
<div class="flex sm:hidden flex-1 justify-between">
|
|
56
|
+
<a
|
|
57
|
+
href="#"
|
|
58
|
+
class="relative inline-flex items-center rounded-md border border-gray-300 bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-50 dark:border-neutral-600 dark:bg-neutral-800 dark:text-neutral-200 dark:hover:bg-neutral-700 {{ currentPage == 1 ? 'opacity-50 cursor-not-allowed' : '' }}"
|
|
59
|
+
data-action="prev"
|
|
60
|
+
>
|
|
61
|
+
Previous
|
|
62
|
+
</a>
|
|
63
|
+
<a
|
|
64
|
+
href="#"
|
|
65
|
+
class="relative ml-3 inline-flex items-center rounded-md border border-gray-300 bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-50 dark:border-neutral-600 dark:bg-neutral-800 dark:text-neutral-200 dark:hover:bg-neutral-700 {{ currentPage == totalPages ? 'opacity-50 cursor-not-allowed' : '' }}"
|
|
66
|
+
data-action="next"
|
|
67
|
+
>
|
|
68
|
+
Next
|
|
69
|
+
</a>
|
|
70
|
+
</div>
|
|
71
|
+
<div class="hidden sm:flex sm:flex-1 sm:items-center sm:justify-between">
|
|
72
|
+
<div>
|
|
73
|
+
<p class="text-gray-700 text-sm dark:text-neutral-300">
|
|
74
|
+
Showing
|
|
75
|
+
<span class="font-medium">{{ startItem }}</span>
|
|
76
|
+
to
|
|
77
|
+
<span class="font-medium">{{ endItem }}</span>
|
|
78
|
+
of
|
|
79
|
+
<span class="font-medium">{{ totalItems }}</span>
|
|
80
|
+
results
|
|
81
|
+
</p>
|
|
82
|
+
</div>
|
|
83
|
+
<div>
|
|
84
|
+
<nav class="inline-flex -space-x-px rounded-md shadow-sm isolate" aria-label="Pagination">
|
|
85
|
+
<a
|
|
86
|
+
href="#"
|
|
87
|
+
class="relative inline-flex items-center rounded-l-md px-2 py-2 text-gray-400 ring-1 ring-inset ring-gray-300 hover:bg-gray-50 focus:z-20 focus:outline-offset-0 dark:ring-neutral-700 dark:hover:bg-neutral-700 {{ currentPage == 1 ? 'opacity-50 cursor-not-allowed' : '' }}"
|
|
88
|
+
data-action="prev"
|
|
89
|
+
>
|
|
90
|
+
<span class="sr-only">Previous</span>
|
|
91
|
+
<div class="h-5 w-5 i-hugeicons-arrow-left-01"></div>
|
|
92
|
+
</a>
|
|
93
|
+
|
|
94
|
+
@foreach(displayedPages as page)
|
|
95
|
+
@if(page != '...')
|
|
96
|
+
<a
|
|
97
|
+
href="#"
|
|
98
|
+
class="{{ page == currentPage ? 'relative z-10 inline-flex items-center bg-blue-600 px-4 py-2 text-sm font-semibold text-white focus:z-20 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-blue-600 dark:bg-blue-700' : 'relative inline-flex items-center px-4 py-2 text-sm font-semibold text-gray-900 ring-1 ring-inset ring-gray-300 hover:bg-gray-50 focus:z-20 focus:outline-offset-0 dark:text-neutral-200 dark:ring-neutral-700 dark:hover:bg-neutral-700' }} cursor-pointer"
|
|
99
|
+
data-action="page"
|
|
100
|
+
data-page="{{ page }}"
|
|
101
|
+
>
|
|
102
|
+
{{ page }}
|
|
103
|
+
</a>
|
|
104
|
+
@else
|
|
105
|
+
<span class="inline-flex relative items-center px-4 py-2 font-semibold text-gray-700 text-sm dark:text-neutral-400 ring-1 ring-gray-300 ring-inset dark:ring-neutral-700 focus:outline-offset-0">
|
|
106
|
+
...
|
|
107
|
+
</span>
|
|
108
|
+
@endif
|
|
109
|
+
@endforeach
|
|
110
|
+
|
|
111
|
+
<a
|
|
112
|
+
href="#"
|
|
113
|
+
class="relative inline-flex items-center rounded-r-md px-2 py-2 text-gray-400 ring-1 ring-inset ring-gray-300 hover:bg-gray-50 focus:z-20 focus:outline-offset-0 dark:ring-neutral-700 dark:hover:bg-neutral-700 {{ currentPage == totalPages ? 'opacity-50 cursor-not-allowed' : '' }}"
|
|
114
|
+
data-action="next"
|
|
115
|
+
>
|
|
116
|
+
<span class="sr-only">Next</span>
|
|
117
|
+
<div class="h-5 w-5 i-hugeicons-arrow-right-01"></div>
|
|
118
|
+
</a>
|
|
119
|
+
</nav>
|
|
120
|
+
</div>
|
|
121
|
+
</div>
|
|
122
|
+
</div>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface SearchFilterProps {
|
|
3
|
+
placeholder?: string
|
|
4
|
+
searchQuery?: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
const { placeholder = 'Search...', searchQuery = '' } = defineProps<SearchFilterProps>()
|
|
8
|
+
</script>
|
|
9
|
+
<div>
|
|
10
|
+
<!-- Search -->
|
|
11
|
+
<div class="relative rounded-md shadow-sm">
|
|
12
|
+
<div class="flex absolute inset-y-0 left-0 items-center pl-3 pointer-events-none">
|
|
13
|
+
<div class="h-5 w-5 text-gray-400 i-hugeicons-search-01"></div>
|
|
14
|
+
</div>
|
|
15
|
+
<input
|
|
16
|
+
type="text"
|
|
17
|
+
class="block pl-10 pr-3 py-2.5 w-full leading-6 text-base text-gray-900 dark:text-white placeholder:text-gray-400 dark:placeholder:text-neutral-500 dark:bg-neutral-800 border-0 ring-1 ring-gray-300 ring-inset rounded-md dark:ring-neutral-700 focus:ring-2 focus:ring-blue-600 focus:ring-inset"
|
|
18
|
+
placeholder="{{ placeholder }}"
|
|
19
|
+
value="{{ searchQuery }}"
|
|
20
|
+
name="search"
|
|
21
|
+
>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface ShippingMethodsTableProps {
|
|
3
|
+
methods?: any[]
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const { methods = [] } = defineProps<ShippingMethodsTableProps>()
|
|
7
|
+
|
|
8
|
+
function formatCurrency(amount) {
|
|
9
|
+
if (!amount) return 'N/A'
|
|
10
|
+
return new Intl.NumberFormat('en-US', {
|
|
11
|
+
style: 'currency',
|
|
12
|
+
currency: 'USD'
|
|
13
|
+
}).format(amount)
|
|
14
|
+
}
|
|
15
|
+
</script>
|
|
16
|
+
<div class="overflow-hidden border border-stone-200/80 rounded-xl dark:border-neutral-700 shadow-sm">
|
|
17
|
+
<table class="min-w-full divide-stone-100 divide-y dark:divide-neutral-700">
|
|
18
|
+
<thead class="bg-stone-50/80 dark:bg-neutral-800">
|
|
19
|
+
<tr>
|
|
20
|
+
<th scope="col" class="pl-6 pr-3 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Name</th>
|
|
21
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Description</th>
|
|
22
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Base Rate</th>
|
|
23
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Handling Fee</th>
|
|
24
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Free Shipping</th>
|
|
25
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Zones</th>
|
|
26
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Status</th>
|
|
27
|
+
<th scope="col" class="relative pl-3 pr-6 py-3.5">
|
|
28
|
+
<span class="sr-only">Actions</span>
|
|
29
|
+
</th>
|
|
30
|
+
</tr>
|
|
31
|
+
</thead>
|
|
32
|
+
<tbody class="bg-white dark:bg-neutral-800 divide-stone-100 divide-y dark:divide-neutral-700">
|
|
33
|
+
@foreach(methods as method)
|
|
34
|
+
<tr class="hover:bg-stone-50/50 dark:hover:bg-neutral-700/50 transition-colors">
|
|
35
|
+
<td class="pl-6 pr-3 py-3.5 font-medium text-sm text-stone-800 whitespace-nowrap dark:text-white">
|
|
36
|
+
{{ method.name }}
|
|
37
|
+
</td>
|
|
38
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
39
|
+
{{ method.description }}
|
|
40
|
+
</td>
|
|
41
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
42
|
+
{{ formatCurrency(method.base_rate) }}
|
|
43
|
+
</td>
|
|
44
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
45
|
+
{{ formatCurrency(method.free_shipping) }}
|
|
46
|
+
</td>
|
|
47
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
48
|
+
@if(method.free_shipping !== null)
|
|
49
|
+
Over {{ formatCurrency(method.free_shipping) }}
|
|
50
|
+
@else
|
|
51
|
+
Not available
|
|
52
|
+
@endif
|
|
53
|
+
</td>
|
|
54
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
55
|
+
<div class="flex flex-wrap gap-1">
|
|
56
|
+
@foreach(method.shipping_zones as zone)
|
|
57
|
+
<span class="inline-flex items-center px-2 py-1 font-medium text-blue-700 text-xs dark:text-blue-300 bg-blue-50 dark:bg-blue-900 rounded-full">
|
|
58
|
+
{{ zone.name }}
|
|
59
|
+
</span>
|
|
60
|
+
@endforeach
|
|
61
|
+
</div>
|
|
62
|
+
</td>
|
|
63
|
+
<td class="px-4 py-3.5 text-sm whitespace-nowrap">
|
|
64
|
+
<span class="inline-flex items-center rounded-full px-3 py-1 text-xs font-medium {{ method.status == 'active' ? 'bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-300' : 'bg-gray-100 text-gray-800 dark:bg-neutral-700 dark:text-neutral-300' }}">
|
|
65
|
+
{{ method.status }}
|
|
66
|
+
</span>
|
|
67
|
+
</td>
|
|
68
|
+
<td class="relative pl-3 pr-6 py-3.5 font-medium text-right text-sm whitespace-nowrap">
|
|
69
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" title="Edit" data-action="edit" data-method-id="{{ method.id }}">
|
|
70
|
+
<div class="h-5 w-5 i-hugeicons-edit-01"></div>
|
|
71
|
+
</button>
|
|
72
|
+
<button type="button" class="p-2 text-stone-400 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300 border border-transparent rounded-md hover:border-red-200 dark:hover:border-red-800 duration-150 transition-colors" title="Delete" data-action="delete" data-method-id="{{ method.id }}">
|
|
73
|
+
<div class="h-5 w-5 i-hugeicons-waste"></div>
|
|
74
|
+
</button>
|
|
75
|
+
</td>
|
|
76
|
+
</tr>
|
|
77
|
+
@endforeach
|
|
78
|
+
</tbody>
|
|
79
|
+
</table>
|
|
80
|
+
</div>
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface ShippingRatesTableProps {
|
|
3
|
+
rates?: any[]
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const { rates = [] } = defineProps<ShippingRatesTableProps>()
|
|
7
|
+
|
|
8
|
+
function formatCurrency(amount) {
|
|
9
|
+
return new Intl.NumberFormat('en-US', {
|
|
10
|
+
style: 'currency',
|
|
11
|
+
currency: 'USD'
|
|
12
|
+
}).format(amount)
|
|
13
|
+
}
|
|
14
|
+
</script>
|
|
15
|
+
<div class="overflow-hidden border border-stone-200/80 rounded-xl dark:border-neutral-700 shadow-sm">
|
|
16
|
+
<table class="min-w-full divide-stone-100 divide-y dark:divide-neutral-700">
|
|
17
|
+
<thead class="bg-stone-50/80 dark:bg-neutral-800">
|
|
18
|
+
<tr>
|
|
19
|
+
<th scope="col" class="pl-6 pr-3 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Method</th>
|
|
20
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Zone</th>
|
|
21
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Weight From</th>
|
|
22
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Weight To</th>
|
|
23
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Rate</th>
|
|
24
|
+
<th scope="col" class="relative pl-3 pr-6 py-3.5">
|
|
25
|
+
<span class="sr-only">Actions</span>
|
|
26
|
+
</th>
|
|
27
|
+
</tr>
|
|
28
|
+
</thead>
|
|
29
|
+
<tbody class="bg-white dark:bg-neutral-800 divide-stone-100 divide-y dark:divide-neutral-700">
|
|
30
|
+
@foreach(rates as rate)
|
|
31
|
+
<tr class="hover:bg-stone-50/50 dark:hover:bg-neutral-700/50 transition-colors">
|
|
32
|
+
<td class="pl-6 pr-3 py-3.5 font-medium text-sm text-stone-800 whitespace-nowrap dark:text-white">
|
|
33
|
+
{{ rate.shipping_method.name }}
|
|
34
|
+
</td>
|
|
35
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
36
|
+
{{ rate.shipping_zone.name }}
|
|
37
|
+
</td>
|
|
38
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
39
|
+
{{ rate.weight_from }} kg
|
|
40
|
+
</td>
|
|
41
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
42
|
+
{{ rate.weight_to }} kg
|
|
43
|
+
</td>
|
|
44
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
45
|
+
{{ formatCurrency(rate.rate) }}
|
|
46
|
+
</td>
|
|
47
|
+
<td class="relative pl-3 pr-6 py-3.5 font-medium text-right text-sm whitespace-nowrap">
|
|
48
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" title="Edit" data-action="edit" data-rate-id="{{ rate.id }}">
|
|
49
|
+
<div class="h-5 w-5 i-hugeicons-edit-01"></div>
|
|
50
|
+
</button>
|
|
51
|
+
<button type="button" class="p-2 text-stone-400 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300 border border-transparent rounded-md hover:border-red-200 dark:hover:border-red-800 duration-150 transition-colors" title="Delete" data-action="delete" data-rate-id="{{ rate.id }}">
|
|
52
|
+
<div class="h-5 w-5 i-hugeicons-waste"></div>
|
|
53
|
+
</button>
|
|
54
|
+
</td>
|
|
55
|
+
</tr>
|
|
56
|
+
@endforeach
|
|
57
|
+
</tbody>
|
|
58
|
+
</table>
|
|
59
|
+
</div>
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface ShippingZonesTableProps {
|
|
3
|
+
zones?: any[]
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const { zones = [] } = defineProps<ShippingZonesTableProps>()
|
|
7
|
+
|
|
8
|
+
function getPostalCodes(postalCodes) {
|
|
9
|
+
if (!postalCodes) return 'All'
|
|
10
|
+
return postalCodes.split(',').map(code => code.trim()).join(', ')
|
|
11
|
+
}
|
|
12
|
+
</script>
|
|
13
|
+
<div class="overflow-hidden border border-stone-200/80 rounded-xl dark:border-neutral-700 shadow-sm">
|
|
14
|
+
<table class="min-w-full divide-stone-100 divide-y dark:divide-neutral-700">
|
|
15
|
+
<thead class="bg-stone-50/80 dark:bg-neutral-800">
|
|
16
|
+
<tr>
|
|
17
|
+
<th scope="col" class="pl-6 pr-3 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Zone Name</th>
|
|
18
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Countries</th>
|
|
19
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Regions</th>
|
|
20
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Postal Codes</th>
|
|
21
|
+
<th scope="col" class="px-4 py-3.5 font-semibold text-left text-stone-500 text-xs tracking-wider uppercase dark:text-neutral-400">Status</th>
|
|
22
|
+
<th scope="col" class="relative pl-3 pr-6 py-3.5">
|
|
23
|
+
<span class="sr-only">Actions</span>
|
|
24
|
+
</th>
|
|
25
|
+
</tr>
|
|
26
|
+
</thead>
|
|
27
|
+
<tbody class="bg-white dark:bg-neutral-800 divide-stone-100 divide-y dark:divide-neutral-700">
|
|
28
|
+
@foreach(zones as zone)
|
|
29
|
+
<tr class="hover:bg-stone-50/50 dark:hover:bg-neutral-700/50 transition-colors">
|
|
30
|
+
<td class="pl-6 pr-3 py-3.5 font-medium text-sm text-stone-800 whitespace-nowrap dark:text-white">
|
|
31
|
+
{{ zone.name }}
|
|
32
|
+
</td>
|
|
33
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
34
|
+
<div class="flex flex-wrap gap-1">
|
|
35
|
+
@foreach(zone.countries as country)
|
|
36
|
+
<span class="inline-flex items-center px-2 py-1 font-medium text-blue-700 text-xs dark:text-blue-300 bg-blue-50 dark:bg-blue-900 rounded-full">
|
|
37
|
+
{{ country }}
|
|
38
|
+
</span>
|
|
39
|
+
@endforeach
|
|
40
|
+
</div>
|
|
41
|
+
</td>
|
|
42
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
43
|
+
<div class="flex flex-wrap gap-1">
|
|
44
|
+
@foreach(zone.regions as region)
|
|
45
|
+
<span class="inline-flex items-center px-2 py-1 font-medium text-green-700 text-xs dark:text-green-300 bg-green-50 dark:bg-green-900 rounded-full">
|
|
46
|
+
{{ region }}
|
|
47
|
+
</span>
|
|
48
|
+
@endforeach
|
|
49
|
+
</div>
|
|
50
|
+
</td>
|
|
51
|
+
<td class="px-4 py-3.5 text-sm text-stone-500 whitespace-nowrap dark:text-neutral-300">
|
|
52
|
+
{{ getPostalCodes(zone.postal_codes) }}
|
|
53
|
+
</td>
|
|
54
|
+
<td class="px-4 py-3.5 text-sm whitespace-nowrap">
|
|
55
|
+
<span class="inline-flex items-center rounded-full px-3 py-1 text-xs font-medium {{ zone.status == 'active' ? 'bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-300' : 'bg-gray-100 text-gray-800 dark:bg-neutral-700 dark:text-neutral-300' }}">
|
|
56
|
+
{{ zone.status }}
|
|
57
|
+
</span>
|
|
58
|
+
</td>
|
|
59
|
+
<td class="relative pl-3 pr-6 py-3.5 font-medium text-right text-sm whitespace-nowrap">
|
|
60
|
+
<button type="button" class="mr-2 p-2 text-stone-400 dark:text-blue-400 hover:text-blue-900 dark:hover:text-blue-300 border border-transparent rounded-md hover:border-blue-200 dark:hover:border-blue-800 duration-150 transition-colors" title="Edit" data-action="edit" data-zone-id="{{ zone.id }}">
|
|
61
|
+
<div class="h-5 w-5 i-hugeicons-edit-01"></div>
|
|
62
|
+
</button>
|
|
63
|
+
<button type="button" class="p-2 text-stone-400 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300 border border-transparent rounded-md hover:border-red-200 dark:hover:border-red-800 duration-150 transition-colors" title="Delete" data-action="delete" data-zone-id="{{ zone.id }}">
|
|
64
|
+
<div class="h-5 w-5 i-hugeicons-waste"></div>
|
|
65
|
+
</button>
|
|
66
|
+
</td>
|
|
67
|
+
</tr>
|
|
68
|
+
@endforeach
|
|
69
|
+
</tbody>
|
|
70
|
+
</table>
|
|
71
|
+
</div>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
interface TabNavigationProps {
|
|
3
|
+
modelValue?: string
|
|
4
|
+
tabs?: any[]
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
const { modelValue = '', tabs = [] } = defineProps<TabNavigationProps>()
|
|
8
|
+
</script>
|
|
9
|
+
<div>
|
|
10
|
+
<div class="sm:hidden">
|
|
11
|
+
<label for="tabs" class="sr-only">Select a tab</label>
|
|
12
|
+
<select
|
|
13
|
+
id="tabs"
|
|
14
|
+
name="tabs"
|
|
15
|
+
class="block w-full dark:text-white dark:bg-neutral-800 border-gray-300 rounded-md dark:border-neutral-700 focus:border-blue-500 focus:ring-blue-500"
|
|
16
|
+
>
|
|
17
|
+
@foreach(tabs as tab)
|
|
18
|
+
<option value="{{ tab }}" {{ tab == modelValue ? 'selected' : '' }}>{{ tab.name }}</option>
|
|
19
|
+
@endforeach
|
|
20
|
+
</select>
|
|
21
|
+
</div>
|
|
22
|
+
<div class="hidden sm:block">
|
|
23
|
+
<div class="border-b border-gray-200 dark:border-neutral-700">
|
|
24
|
+
<nav class="flex -mb-px space-x-8" aria-label="Tabs">
|
|
25
|
+
@foreach(tabs as tab)
|
|
26
|
+
<a
|
|
27
|
+
href="{{ tab.href }}"
|
|
28
|
+
class="{{ tab == modelValue ? 'border-blue-500 text-blue-600 dark:border-blue-400 dark:text-blue-400' : 'border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 dark:text-neutral-400 dark:hover:border-gray-600 dark:hover:text-gray-300' }} whitespace-nowrap border-b-2 py-4 px-1 text-sm font-medium"
|
|
29
|
+
>
|
|
30
|
+
{{ tab.name }}
|
|
31
|
+
</a>
|
|
32
|
+
@endforeach
|
|
33
|
+
</nav>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|