@flaredev/cli 0.2.0 → 0.3.0

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.
Files changed (64) hide show
  1. package/bin/flare.js +9 -1
  2. package/dist/index.js +751 -280
  3. package/package.json +2 -2
  4. package/templates/app/app/admin/page.tsx +9 -61
  5. package/templates/app/app/dashboard/account/page.tsx +6 -4
  6. package/templates/app/app/{admin → dashboard}/actions.ts +109 -11
  7. package/templates/app/app/dashboard/import-actions.ts +91 -0
  8. package/templates/app/app/dashboard/layout.tsx +42 -39
  9. package/templates/app/app/dashboard/observability/page.tsx +174 -0
  10. package/templates/app/app/dashboard/page.tsx +106 -25
  11. package/templates/app/app/verify-email/page.tsx +33 -0
  12. package/templates/app/components/account/security-settings.tsx +6 -9
  13. package/templates/app/components/auth/otp-input.tsx +95 -0
  14. package/templates/app/components/auth/password-field.tsx +116 -0
  15. package/templates/app/components/auth/password-forms.tsx +76 -79
  16. package/templates/app/components/auth/sign-in-flow.tsx +306 -315
  17. package/templates/app/components/auth/sign-up-form.tsx +93 -101
  18. package/templates/app/components/auth/two-factor-form.tsx +139 -124
  19. package/templates/app/components/auth/use-resend.ts +44 -0
  20. package/templates/app/components/auth/verify-email-form.tsx +135 -0
  21. package/templates/app/components/{admin/admin-header.tsx → dashboard/dashboard-header.tsx} +78 -78
  22. package/templates/app/components/{admin/resource-nav.tsx → dashboard/dashboard-sidebar.tsx} +166 -120
  23. package/templates/app/components/dashboard/export-button.tsx +41 -0
  24. package/templates/app/components/{admin → dashboard}/fields/file-field.tsx +302 -302
  25. package/templates/app/components/dashboard/import-dialog.tsx +487 -0
  26. package/templates/app/components/dashboard/page-header.tsx +57 -0
  27. package/templates/app/components/dashboard/resource-form-dialog.tsx +80 -0
  28. package/templates/app/components/{admin → dashboard}/resource-form-page.tsx +61 -55
  29. package/templates/app/components/{admin → dashboard}/resource-form.tsx +165 -139
  30. package/templates/app/components/dashboard/resource-stats.tsx +53 -0
  31. package/templates/app/components/{admin → dashboard}/resource-table.tsx +331 -281
  32. package/templates/app/components/{admin → dashboard}/row-actions.tsx +144 -111
  33. package/templates/app/components/dashboard/stat-card.tsx +69 -0
  34. package/templates/app/components/dashboard/table-selection.tsx +185 -0
  35. package/templates/app/components/dashboard/traffic-chart.tsx +32 -0
  36. package/templates/app/db/flare-schema.ts +33 -1
  37. package/templates/app/lib/analytics.ts +121 -0
  38. package/templates/app/lib/audit.ts +80 -0
  39. package/templates/app/lib/auth-config.ts +38 -33
  40. package/templates/app/lib/auth.ts +34 -0
  41. package/templates/app/lib/cache.ts +83 -83
  42. package/templates/app/lib/csv.ts +24 -0
  43. package/templates/app/lib/dashboard-nav.ts +15 -0
  44. package/templates/app/lib/{admin.ts → dashboard.ts} +138 -103
  45. package/templates/app/lib/password-rules.ts +159 -0
  46. package/templates/app/lib/site.ts +56 -47
  47. package/templates/app/migrations/0000_init.sql +15 -3
  48. package/templates/app/migrations/meta/0000_snapshot.json +97 -1
  49. package/templates/app/migrations/meta/_journal.json +1 -1
  50. package/templates/app/worker-configuration.d.ts +15764 -0
  51. package/templates/locks/package-lock.json +9189 -0
  52. package/templates/locks/pnpm-lock.yaml +6347 -0
  53. package/templates/app/app/admin/layout.tsx +0 -32
  54. package/templates/app/components/dashboard/dashboard-nav.tsx +0 -35
  55. package/templates/app/lib/admin-nav.ts +0 -15
  56. /package/templates/app/components/{admin → dashboard}/fields/country-field.tsx +0 -0
  57. /package/templates/app/components/{admin → dashboard}/fields/date-field.tsx +0 -0
  58. /package/templates/app/components/{admin → dashboard}/fields/field-widget.tsx +0 -0
  59. /package/templates/app/components/{admin → dashboard}/fields/multi-select-field.tsx +0 -0
  60. /package/templates/app/components/{admin → dashboard}/fields/phone-field.tsx +0 -0
  61. /package/templates/app/components/{admin → dashboard}/fields/relation-field.tsx +0 -0
  62. /package/templates/app/components/{admin → dashboard}/query.ts +0 -0
  63. /package/templates/app/components/{admin → dashboard}/resource-icon.tsx +0 -0
  64. /package/templates/app/components/{admin → dashboard}/resource-table-toolbar.tsx +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": "6",
3
3
  "dialect": "sqlite",
4
- "id": "79194ad1-2287-43f7-8f37-64fded59352b",
4
+ "id": "b98aab68-42f4-4832-ac5d-de8a121d8eae",
5
5
  "prevId": "00000000-0000-0000-0000-000000000000",
6
6
  "tables": {
7
7
  "account": {
@@ -606,6 +606,102 @@
606
606
  "uniqueConstraints": {},
607
607
  "checkConstraints": {}
608
608
  },
609
+ "audit_log": {
610
+ "name": "audit_log",
611
+ "columns": {
612
+ "id": {
613
+ "name": "id",
614
+ "type": "text",
615
+ "primaryKey": true,
616
+ "notNull": true,
617
+ "autoincrement": false
618
+ },
619
+ "action": {
620
+ "name": "action",
621
+ "type": "text",
622
+ "primaryKey": false,
623
+ "notNull": true,
624
+ "autoincrement": false
625
+ },
626
+ "resource": {
627
+ "name": "resource",
628
+ "type": "text",
629
+ "primaryKey": false,
630
+ "notNull": true,
631
+ "autoincrement": false
632
+ },
633
+ "record_id": {
634
+ "name": "record_id",
635
+ "type": "text",
636
+ "primaryKey": false,
637
+ "notNull": false,
638
+ "autoincrement": false
639
+ },
640
+ "record_label": {
641
+ "name": "record_label",
642
+ "type": "text",
643
+ "primaryKey": false,
644
+ "notNull": false,
645
+ "autoincrement": false
646
+ },
647
+ "user_id": {
648
+ "name": "user_id",
649
+ "type": "text",
650
+ "primaryKey": false,
651
+ "notNull": false,
652
+ "autoincrement": false
653
+ },
654
+ "user_email": {
655
+ "name": "user_email",
656
+ "type": "text",
657
+ "primaryKey": false,
658
+ "notNull": false,
659
+ "autoincrement": false
660
+ },
661
+ "changes": {
662
+ "name": "changes",
663
+ "type": "text",
664
+ "primaryKey": false,
665
+ "notNull": false,
666
+ "autoincrement": false
667
+ },
668
+ "ip": {
669
+ "name": "ip",
670
+ "type": "text",
671
+ "primaryKey": false,
672
+ "notNull": false,
673
+ "autoincrement": false
674
+ },
675
+ "created_at": {
676
+ "name": "created_at",
677
+ "type": "integer",
678
+ "primaryKey": false,
679
+ "notNull": true,
680
+ "autoincrement": false,
681
+ "default": "(cast(unixepoch('subsecond') * 1000 as integer))"
682
+ }
683
+ },
684
+ "indexes": {
685
+ "audit_log_created_at_idx": {
686
+ "name": "audit_log_created_at_idx",
687
+ "columns": [
688
+ "created_at"
689
+ ],
690
+ "isUnique": false
691
+ },
692
+ "audit_log_resource_idx": {
693
+ "name": "audit_log_resource_idx",
694
+ "columns": [
695
+ "resource"
696
+ ],
697
+ "isUnique": false
698
+ }
699
+ },
700
+ "foreignKeys": {},
701
+ "compositePrimaryKeys": {},
702
+ "uniqueConstraints": {},
703
+ "checkConstraints": {}
704
+ },
609
705
  "role": {
610
706
  "name": "role",
611
707
  "columns": {
@@ -5,7 +5,7 @@
5
5
  {
6
6
  "idx": 0,
7
7
  "version": "6",
8
- "when": 1790089765410,
8
+ "when": 1790112915429,
9
9
  "tag": "0000_init",
10
10
  "breakpoints": true
11
11
  }