@contractspec/example.saas-boilerplate 3.7.6 → 3.8.2
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/.turbo/turbo-build.log +39 -27
- package/AGENTS.md +50 -27
- package/CHANGELOG.md +36 -0
- package/README.md +65 -144
- package/dist/billing/billing.event.js +1 -1
- package/dist/billing/index.d.ts +6 -6
- package/dist/billing/index.js +1 -1
- package/dist/browser/billing/billing.event.js +1 -1
- package/dist/browser/billing/index.js +1 -1
- package/dist/browser/index.js +1147 -869
- package/dist/browser/project/index.js +209 -209
- package/dist/browser/project/project.event.js +1 -1
- package/dist/browser/saas-boilerplate.feature.js +208 -0
- package/dist/browser/ui/SaasDashboard.js +356 -105
- package/dist/browser/ui/SaasDashboard.visualizations.js +249 -0
- package/dist/browser/ui/SaasProjectList.js +7 -7
- package/dist/browser/ui/SaasSettingsPanel.js +12 -12
- package/dist/browser/ui/hooks/index.js +2 -2
- package/dist/browser/ui/hooks/useProjectList.js +1 -1
- package/dist/browser/ui/hooks/useProjectMutations.js +1 -1
- package/dist/browser/ui/index.js +790 -521
- package/dist/browser/ui/modals/CreateProjectModal.js +10 -10
- package/dist/browser/ui/modals/ProjectActionsModal.js +13 -13
- package/dist/browser/ui/modals/index.js +23 -23
- package/dist/browser/ui/renderers/index.js +341 -115
- package/dist/browser/ui/renderers/project-list.markdown.js +229 -3
- package/dist/browser/ui/renderers/project-list.renderer.js +7 -7
- package/dist/browser/visualizations/catalog.js +155 -0
- package/dist/browser/visualizations/index.js +217 -0
- package/dist/browser/visualizations/selectors.js +210 -0
- package/dist/handlers/index.d.ts +2 -2
- package/dist/index.d.ts +5 -4
- package/dist/index.js +1147 -869
- package/dist/node/billing/billing.event.js +1 -1
- package/dist/node/billing/index.js +1 -1
- package/dist/node/index.js +1147 -869
- package/dist/node/project/index.js +209 -209
- package/dist/node/project/project.event.js +1 -1
- package/dist/node/saas-boilerplate.feature.js +208 -0
- package/dist/node/ui/SaasDashboard.js +356 -105
- package/dist/node/ui/SaasDashboard.visualizations.js +249 -0
- package/dist/node/ui/SaasProjectList.js +7 -7
- package/dist/node/ui/SaasSettingsPanel.js +12 -12
- package/dist/node/ui/hooks/index.js +2 -2
- package/dist/node/ui/hooks/useProjectList.js +1 -1
- package/dist/node/ui/hooks/useProjectMutations.js +1 -1
- package/dist/node/ui/index.js +790 -521
- package/dist/node/ui/modals/CreateProjectModal.js +10 -10
- package/dist/node/ui/modals/ProjectActionsModal.js +13 -13
- package/dist/node/ui/modals/index.js +23 -23
- package/dist/node/ui/renderers/index.js +341 -115
- package/dist/node/ui/renderers/project-list.markdown.js +229 -3
- package/dist/node/ui/renderers/project-list.renderer.js +7 -7
- package/dist/node/visualizations/catalog.js +155 -0
- package/dist/node/visualizations/index.js +217 -0
- package/dist/node/visualizations/selectors.js +210 -0
- package/dist/presentations/index.d.ts +1 -1
- package/dist/project/index.d.ts +7 -7
- package/dist/project/index.js +209 -209
- package/dist/project/project.event.js +1 -1
- package/dist/saas-boilerplate.feature.js +208 -0
- package/dist/settings/index.d.ts +1 -1
- package/dist/ui/SaasDashboard.js +356 -105
- package/dist/ui/SaasDashboard.visualizations.d.ts +5 -0
- package/dist/ui/SaasDashboard.visualizations.js +250 -0
- package/dist/ui/SaasProjectList.js +7 -7
- package/dist/ui/SaasSettingsPanel.js +12 -12
- package/dist/ui/hooks/index.d.ts +2 -2
- package/dist/ui/hooks/index.js +2 -2
- package/dist/ui/hooks/useProjectList.d.ts +5 -0
- package/dist/ui/hooks/useProjectList.js +1 -1
- package/dist/ui/hooks/useProjectMutations.d.ts +8 -0
- package/dist/ui/hooks/useProjectMutations.js +1 -1
- package/dist/ui/index.d.ts +4 -4
- package/dist/ui/index.js +790 -521
- package/dist/ui/modals/CreateProjectModal.js +10 -10
- package/dist/ui/modals/ProjectActionsModal.js +13 -13
- package/dist/ui/modals/index.js +23 -23
- package/dist/ui/renderers/index.d.ts +1 -1
- package/dist/ui/renderers/index.js +341 -115
- package/dist/ui/renderers/project-list.markdown.js +229 -3
- package/dist/ui/renderers/project-list.renderer.d.ts +1 -1
- package/dist/ui/renderers/project-list.renderer.js +7 -7
- package/dist/visualizations/catalog.d.ts +11 -0
- package/dist/visualizations/catalog.js +156 -0
- package/dist/visualizations/index.d.ts +2 -0
- package/dist/visualizations/index.js +218 -0
- package/dist/visualizations/selectors.d.ts +8 -0
- package/dist/visualizations/selectors.js +211 -0
- package/dist/visualizations/selectors.test.d.ts +1 -0
- package/package.json +70 -14
- package/src/billing/billing.entity.ts +132 -132
- package/src/billing/billing.enum.ts +9 -9
- package/src/billing/billing.event.ts +71 -71
- package/src/billing/billing.handler.ts +87 -87
- package/src/billing/billing.operations.ts +158 -158
- package/src/billing/billing.presentation.ts +45 -45
- package/src/billing/billing.schema.ts +76 -76
- package/src/billing/index.ts +43 -48
- package/src/dashboard/dashboard.presentation.ts +45 -45
- package/src/dashboard/index.ts +2 -2
- package/src/docs/saas-boilerplate.docblock.ts +43 -43
- package/src/example.ts +32 -32
- package/src/handlers/index.ts +9 -9
- package/src/handlers/saas.handlers.ts +250 -249
- package/src/index.ts +41 -41
- package/src/presentations/index.ts +18 -20
- package/src/project/index.ts +45 -50
- package/src/project/project.entity.ts +68 -68
- package/src/project/project.enum.ts +8 -8
- package/src/project/project.event.ts +79 -79
- package/src/project/project.handler.ts +103 -103
- package/src/project/project.operations.ts +236 -236
- package/src/project/project.presentation.ts +46 -46
- package/src/project/project.schema.ts +90 -90
- package/src/saas-boilerplate.feature.ts +103 -100
- package/src/seeders/index.ts +20 -20
- package/src/settings/index.ts +2 -3
- package/src/settings/settings.entity.ts +65 -65
- package/src/settings/settings.enum.ts +4 -4
- package/src/shared/mock-data.ts +92 -92
- package/src/shared/overlay-types.ts +23 -23
- package/src/tests/operations.test-spec.ts +96 -96
- package/src/ui/SaasDashboard.tsx +278 -270
- package/src/ui/SaasDashboard.visualizations.tsx +41 -0
- package/src/ui/SaasProjectList.tsx +90 -90
- package/src/ui/SaasSettingsPanel.tsx +84 -84
- package/src/ui/hooks/index.ts +3 -3
- package/src/ui/hooks/useProjectList.ts +69 -68
- package/src/ui/hooks/useProjectMutations.ts +144 -143
- package/src/ui/index.ts +8 -12
- package/src/ui/modals/CreateProjectModal.tsx +154 -154
- package/src/ui/modals/ProjectActionsModal.tsx +321 -321
- package/src/ui/overlays/demo-overlays.ts +49 -49
- package/src/ui/renderers/index.ts +5 -4
- package/src/ui/renderers/project-list.markdown.ts +229 -205
- package/src/ui/renderers/project-list.renderer.tsx +14 -13
- package/src/visualizations/catalog.ts +153 -0
- package/src/visualizations/index.ts +2 -0
- package/src/visualizations/selectors.test.ts +25 -0
- package/src/visualizations/selectors.ts +85 -0
- package/tsconfig.json +7 -8
- package/tsdown.config.js +7 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/ui/modals/CreateProjectModal.tsx
|
|
2
|
-
import { useState } from "react";
|
|
3
2
|
import { Button, Input } from "@contractspec/lib.design-system";
|
|
3
|
+
import { useState } from "react";
|
|
4
4
|
import { jsxDEV } from "react/jsx-dev-runtime";
|
|
5
5
|
"use client";
|
|
6
6
|
var TIERS = [
|
|
@@ -45,7 +45,7 @@ function CreateProjectModal({
|
|
|
45
45
|
className: "fixed inset-0 z-50 flex items-center justify-center",
|
|
46
46
|
children: [
|
|
47
47
|
/* @__PURE__ */ jsxDEV("div", {
|
|
48
|
-
className: "bg-background/80
|
|
48
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm",
|
|
49
49
|
onClick: onClose,
|
|
50
50
|
role: "button",
|
|
51
51
|
tabIndex: 0,
|
|
@@ -56,10 +56,10 @@ function CreateProjectModal({
|
|
|
56
56
|
"aria-label": "Close modal"
|
|
57
57
|
}, undefined, false, undefined, this),
|
|
58
58
|
/* @__PURE__ */ jsxDEV("div", {
|
|
59
|
-
className: "
|
|
59
|
+
className: "relative z-10 w-full max-w-md rounded-xl border border-border bg-card p-6 shadow-xl",
|
|
60
60
|
children: [
|
|
61
61
|
/* @__PURE__ */ jsxDEV("h2", {
|
|
62
|
-
className: "mb-4 text-xl
|
|
62
|
+
className: "mb-4 font-semibold text-xl",
|
|
63
63
|
children: "Create New Project"
|
|
64
64
|
}, undefined, false, undefined, this),
|
|
65
65
|
/* @__PURE__ */ jsxDEV("form", {
|
|
@@ -70,7 +70,7 @@ function CreateProjectModal({
|
|
|
70
70
|
children: [
|
|
71
71
|
/* @__PURE__ */ jsxDEV("label", {
|
|
72
72
|
htmlFor: "project-name",
|
|
73
|
-
className: "
|
|
73
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
74
74
|
children: "Project Name *"
|
|
75
75
|
}, undefined, false, undefined, this),
|
|
76
76
|
/* @__PURE__ */ jsxDEV(Input, {
|
|
@@ -86,7 +86,7 @@ function CreateProjectModal({
|
|
|
86
86
|
children: [
|
|
87
87
|
/* @__PURE__ */ jsxDEV("label", {
|
|
88
88
|
htmlFor: "project-description",
|
|
89
|
-
className: "
|
|
89
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
90
90
|
children: "Description"
|
|
91
91
|
}, undefined, false, undefined, this),
|
|
92
92
|
/* @__PURE__ */ jsxDEV("textarea", {
|
|
@@ -96,7 +96,7 @@ function CreateProjectModal({
|
|
|
96
96
|
placeholder: "Describe what this project is about...",
|
|
97
97
|
rows: 3,
|
|
98
98
|
disabled: isLoading,
|
|
99
|
-
className: "
|
|
99
|
+
className: "w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50"
|
|
100
100
|
}, undefined, false, undefined, this)
|
|
101
101
|
]
|
|
102
102
|
}, undefined, true, undefined, this),
|
|
@@ -104,7 +104,7 @@ function CreateProjectModal({
|
|
|
104
104
|
children: [
|
|
105
105
|
/* @__PURE__ */ jsxDEV("label", {
|
|
106
106
|
htmlFor: "project-tier",
|
|
107
|
-
className: "
|
|
107
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
108
108
|
children: "Tier"
|
|
109
109
|
}, undefined, false, undefined, this),
|
|
110
110
|
/* @__PURE__ */ jsxDEV("select", {
|
|
@@ -112,7 +112,7 @@ function CreateProjectModal({
|
|
|
112
112
|
value: tier,
|
|
113
113
|
onChange: (e) => setTier(e.target.value),
|
|
114
114
|
disabled: isLoading,
|
|
115
|
-
className: "
|
|
115
|
+
className: "h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50",
|
|
116
116
|
children: TIERS.map((t) => /* @__PURE__ */ jsxDEV("option", {
|
|
117
117
|
value: t.value,
|
|
118
118
|
children: t.label
|
|
@@ -121,7 +121,7 @@ function CreateProjectModal({
|
|
|
121
121
|
]
|
|
122
122
|
}, undefined, true, undefined, this),
|
|
123
123
|
error && /* @__PURE__ */ jsxDEV("div", {
|
|
124
|
-
className: "bg-destructive/10
|
|
124
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
125
125
|
children: error
|
|
126
126
|
}, undefined, false, undefined, this),
|
|
127
127
|
/* @__PURE__ */ jsxDEV("div", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/ui/modals/ProjectActionsModal.tsx
|
|
2
|
-
import { useEffect, useState } from "react";
|
|
3
2
|
import { Button, Input } from "@contractspec/lib.design-system";
|
|
3
|
+
import { useEffect, useState } from "react";
|
|
4
4
|
import { jsxDEV } from "react/jsx-dev-runtime";
|
|
5
5
|
"use client";
|
|
6
6
|
function ProjectActionsModal({
|
|
@@ -93,7 +93,7 @@ function ProjectActionsModal({
|
|
|
93
93
|
className: "fixed inset-0 z-50 flex items-center justify-center",
|
|
94
94
|
children: [
|
|
95
95
|
/* @__PURE__ */ jsxDEV("div", {
|
|
96
|
-
className: "bg-background/80
|
|
96
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm",
|
|
97
97
|
onClick: handleClose,
|
|
98
98
|
role: "button",
|
|
99
99
|
tabIndex: 0,
|
|
@@ -104,13 +104,13 @@ function ProjectActionsModal({
|
|
|
104
104
|
"aria-label": "Close modal"
|
|
105
105
|
}, undefined, false, undefined, this),
|
|
106
106
|
/* @__PURE__ */ jsxDEV("div", {
|
|
107
|
-
className: "
|
|
107
|
+
className: "relative z-10 w-full max-w-md rounded-xl border border-border bg-card p-6 shadow-xl",
|
|
108
108
|
children: [
|
|
109
109
|
/* @__PURE__ */ jsxDEV("div", {
|
|
110
|
-
className: "
|
|
110
|
+
className: "mb-4 border-border border-b pb-4",
|
|
111
111
|
children: [
|
|
112
112
|
/* @__PURE__ */ jsxDEV("h2", {
|
|
113
|
-
className: "text-xl
|
|
113
|
+
className: "font-semibold text-xl",
|
|
114
114
|
children: project.name
|
|
115
115
|
}, undefined, false, undefined, this),
|
|
116
116
|
/* @__PURE__ */ jsxDEV("p", {
|
|
@@ -192,7 +192,7 @@ function ProjectActionsModal({
|
|
|
192
192
|
children: [
|
|
193
193
|
/* @__PURE__ */ jsxDEV("label", {
|
|
194
194
|
htmlFor: "edit-name",
|
|
195
|
-
className: "
|
|
195
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
196
196
|
children: "Project Name *"
|
|
197
197
|
}, undefined, false, undefined, this),
|
|
198
198
|
/* @__PURE__ */ jsxDEV(Input, {
|
|
@@ -207,7 +207,7 @@ function ProjectActionsModal({
|
|
|
207
207
|
children: [
|
|
208
208
|
/* @__PURE__ */ jsxDEV("label", {
|
|
209
209
|
htmlFor: "edit-description",
|
|
210
|
-
className: "
|
|
210
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
211
211
|
children: "Description"
|
|
212
212
|
}, undefined, false, undefined, this),
|
|
213
213
|
/* @__PURE__ */ jsxDEV("textarea", {
|
|
@@ -216,12 +216,12 @@ function ProjectActionsModal({
|
|
|
216
216
|
onChange: (e) => setDescription(e.target.value),
|
|
217
217
|
rows: 3,
|
|
218
218
|
disabled: isLoading,
|
|
219
|
-
className: "
|
|
219
|
+
className: "w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50"
|
|
220
220
|
}, undefined, false, undefined, this)
|
|
221
221
|
]
|
|
222
222
|
}, undefined, true, undefined, this),
|
|
223
223
|
error && /* @__PURE__ */ jsxDEV("div", {
|
|
224
|
-
className: "bg-destructive/10
|
|
224
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
225
225
|
children: error
|
|
226
226
|
}, undefined, false, undefined, this),
|
|
227
227
|
/* @__PURE__ */ jsxDEV("div", {
|
|
@@ -251,7 +251,7 @@ function ProjectActionsModal({
|
|
|
251
251
|
"Are you sure you want to archive",
|
|
252
252
|
" ",
|
|
253
253
|
/* @__PURE__ */ jsxDEV("span", {
|
|
254
|
-
className: "text-foreground
|
|
254
|
+
className: "font-medium text-foreground",
|
|
255
255
|
children: project.name
|
|
256
256
|
}, undefined, false, undefined, this),
|
|
257
257
|
"?"
|
|
@@ -262,7 +262,7 @@ function ProjectActionsModal({
|
|
|
262
262
|
children: "Archived projects can be restored later."
|
|
263
263
|
}, undefined, false, undefined, this),
|
|
264
264
|
error && /* @__PURE__ */ jsxDEV("div", {
|
|
265
|
-
className: "bg-destructive/10
|
|
265
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
266
266
|
children: error
|
|
267
267
|
}, undefined, false, undefined, this),
|
|
268
268
|
/* @__PURE__ */ jsxDEV("div", {
|
|
@@ -292,7 +292,7 @@ function ProjectActionsModal({
|
|
|
292
292
|
"Are you sure you want to delete",
|
|
293
293
|
" ",
|
|
294
294
|
/* @__PURE__ */ jsxDEV("span", {
|
|
295
|
-
className: "text-foreground
|
|
295
|
+
className: "font-medium text-foreground",
|
|
296
296
|
children: project.name
|
|
297
297
|
}, undefined, false, undefined, this),
|
|
298
298
|
"?"
|
|
@@ -303,7 +303,7 @@ function ProjectActionsModal({
|
|
|
303
303
|
children: "This action cannot be undone."
|
|
304
304
|
}, undefined, false, undefined, this),
|
|
305
305
|
error && /* @__PURE__ */ jsxDEV("div", {
|
|
306
|
-
className: "bg-destructive/10
|
|
306
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
307
307
|
children: error
|
|
308
308
|
}, undefined, false, undefined, this),
|
|
309
309
|
/* @__PURE__ */ jsxDEV("div", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/ui/modals/CreateProjectModal.tsx
|
|
2
|
-
import { useState } from "react";
|
|
3
2
|
import { Button, Input } from "@contractspec/lib.design-system";
|
|
3
|
+
import { useState } from "react";
|
|
4
4
|
import { jsxDEV } from "react/jsx-dev-runtime";
|
|
5
5
|
"use client";
|
|
6
6
|
var TIERS = [
|
|
@@ -45,7 +45,7 @@ function CreateProjectModal({
|
|
|
45
45
|
className: "fixed inset-0 z-50 flex items-center justify-center",
|
|
46
46
|
children: [
|
|
47
47
|
/* @__PURE__ */ jsxDEV("div", {
|
|
48
|
-
className: "bg-background/80
|
|
48
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm",
|
|
49
49
|
onClick: onClose,
|
|
50
50
|
role: "button",
|
|
51
51
|
tabIndex: 0,
|
|
@@ -56,10 +56,10 @@ function CreateProjectModal({
|
|
|
56
56
|
"aria-label": "Close modal"
|
|
57
57
|
}, undefined, false, undefined, this),
|
|
58
58
|
/* @__PURE__ */ jsxDEV("div", {
|
|
59
|
-
className: "
|
|
59
|
+
className: "relative z-10 w-full max-w-md rounded-xl border border-border bg-card p-6 shadow-xl",
|
|
60
60
|
children: [
|
|
61
61
|
/* @__PURE__ */ jsxDEV("h2", {
|
|
62
|
-
className: "mb-4 text-xl
|
|
62
|
+
className: "mb-4 font-semibold text-xl",
|
|
63
63
|
children: "Create New Project"
|
|
64
64
|
}, undefined, false, undefined, this),
|
|
65
65
|
/* @__PURE__ */ jsxDEV("form", {
|
|
@@ -70,7 +70,7 @@ function CreateProjectModal({
|
|
|
70
70
|
children: [
|
|
71
71
|
/* @__PURE__ */ jsxDEV("label", {
|
|
72
72
|
htmlFor: "project-name",
|
|
73
|
-
className: "
|
|
73
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
74
74
|
children: "Project Name *"
|
|
75
75
|
}, undefined, false, undefined, this),
|
|
76
76
|
/* @__PURE__ */ jsxDEV(Input, {
|
|
@@ -86,7 +86,7 @@ function CreateProjectModal({
|
|
|
86
86
|
children: [
|
|
87
87
|
/* @__PURE__ */ jsxDEV("label", {
|
|
88
88
|
htmlFor: "project-description",
|
|
89
|
-
className: "
|
|
89
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
90
90
|
children: "Description"
|
|
91
91
|
}, undefined, false, undefined, this),
|
|
92
92
|
/* @__PURE__ */ jsxDEV("textarea", {
|
|
@@ -96,7 +96,7 @@ function CreateProjectModal({
|
|
|
96
96
|
placeholder: "Describe what this project is about...",
|
|
97
97
|
rows: 3,
|
|
98
98
|
disabled: isLoading,
|
|
99
|
-
className: "
|
|
99
|
+
className: "w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50"
|
|
100
100
|
}, undefined, false, undefined, this)
|
|
101
101
|
]
|
|
102
102
|
}, undefined, true, undefined, this),
|
|
@@ -104,7 +104,7 @@ function CreateProjectModal({
|
|
|
104
104
|
children: [
|
|
105
105
|
/* @__PURE__ */ jsxDEV("label", {
|
|
106
106
|
htmlFor: "project-tier",
|
|
107
|
-
className: "
|
|
107
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
108
108
|
children: "Tier"
|
|
109
109
|
}, undefined, false, undefined, this),
|
|
110
110
|
/* @__PURE__ */ jsxDEV("select", {
|
|
@@ -112,7 +112,7 @@ function CreateProjectModal({
|
|
|
112
112
|
value: tier,
|
|
113
113
|
onChange: (e) => setTier(e.target.value),
|
|
114
114
|
disabled: isLoading,
|
|
115
|
-
className: "
|
|
115
|
+
className: "h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50",
|
|
116
116
|
children: TIERS.map((t) => /* @__PURE__ */ jsxDEV("option", {
|
|
117
117
|
value: t.value,
|
|
118
118
|
children: t.label
|
|
@@ -121,7 +121,7 @@ function CreateProjectModal({
|
|
|
121
121
|
]
|
|
122
122
|
}, undefined, true, undefined, this),
|
|
123
123
|
error && /* @__PURE__ */ jsxDEV("div", {
|
|
124
|
-
className: "bg-destructive/10
|
|
124
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
125
125
|
children: error
|
|
126
126
|
}, undefined, false, undefined, this),
|
|
127
127
|
/* @__PURE__ */ jsxDEV("div", {
|
|
@@ -150,8 +150,8 @@ function CreateProjectModal({
|
|
|
150
150
|
}
|
|
151
151
|
|
|
152
152
|
// src/ui/modals/ProjectActionsModal.tsx
|
|
153
|
-
import { useEffect, useState as useState2 } from "react";
|
|
154
153
|
import { Button as Button2, Input as Input2 } from "@contractspec/lib.design-system";
|
|
154
|
+
import { useEffect, useState as useState2 } from "react";
|
|
155
155
|
import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
|
|
156
156
|
"use client";
|
|
157
157
|
function ProjectActionsModal({
|
|
@@ -244,7 +244,7 @@ function ProjectActionsModal({
|
|
|
244
244
|
className: "fixed inset-0 z-50 flex items-center justify-center",
|
|
245
245
|
children: [
|
|
246
246
|
/* @__PURE__ */ jsxDEV2("div", {
|
|
247
|
-
className: "bg-background/80
|
|
247
|
+
className: "absolute inset-0 bg-background/80 backdrop-blur-sm",
|
|
248
248
|
onClick: handleClose,
|
|
249
249
|
role: "button",
|
|
250
250
|
tabIndex: 0,
|
|
@@ -255,13 +255,13 @@ function ProjectActionsModal({
|
|
|
255
255
|
"aria-label": "Close modal"
|
|
256
256
|
}, undefined, false, undefined, this),
|
|
257
257
|
/* @__PURE__ */ jsxDEV2("div", {
|
|
258
|
-
className: "
|
|
258
|
+
className: "relative z-10 w-full max-w-md rounded-xl border border-border bg-card p-6 shadow-xl",
|
|
259
259
|
children: [
|
|
260
260
|
/* @__PURE__ */ jsxDEV2("div", {
|
|
261
|
-
className: "
|
|
261
|
+
className: "mb-4 border-border border-b pb-4",
|
|
262
262
|
children: [
|
|
263
263
|
/* @__PURE__ */ jsxDEV2("h2", {
|
|
264
|
-
className: "text-xl
|
|
264
|
+
className: "font-semibold text-xl",
|
|
265
265
|
children: project.name
|
|
266
266
|
}, undefined, false, undefined, this),
|
|
267
267
|
/* @__PURE__ */ jsxDEV2("p", {
|
|
@@ -343,7 +343,7 @@ function ProjectActionsModal({
|
|
|
343
343
|
children: [
|
|
344
344
|
/* @__PURE__ */ jsxDEV2("label", {
|
|
345
345
|
htmlFor: "edit-name",
|
|
346
|
-
className: "
|
|
346
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
347
347
|
children: "Project Name *"
|
|
348
348
|
}, undefined, false, undefined, this),
|
|
349
349
|
/* @__PURE__ */ jsxDEV2(Input2, {
|
|
@@ -358,7 +358,7 @@ function ProjectActionsModal({
|
|
|
358
358
|
children: [
|
|
359
359
|
/* @__PURE__ */ jsxDEV2("label", {
|
|
360
360
|
htmlFor: "edit-description",
|
|
361
|
-
className: "
|
|
361
|
+
className: "mb-1 block font-medium text-muted-foreground text-sm",
|
|
362
362
|
children: "Description"
|
|
363
363
|
}, undefined, false, undefined, this),
|
|
364
364
|
/* @__PURE__ */ jsxDEV2("textarea", {
|
|
@@ -367,12 +367,12 @@ function ProjectActionsModal({
|
|
|
367
367
|
onChange: (e) => setDescription(e.target.value),
|
|
368
368
|
rows: 3,
|
|
369
369
|
disabled: isLoading,
|
|
370
|
-
className: "
|
|
370
|
+
className: "w-full rounded-md border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50"
|
|
371
371
|
}, undefined, false, undefined, this)
|
|
372
372
|
]
|
|
373
373
|
}, undefined, true, undefined, this),
|
|
374
374
|
error && /* @__PURE__ */ jsxDEV2("div", {
|
|
375
|
-
className: "bg-destructive/10
|
|
375
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
376
376
|
children: error
|
|
377
377
|
}, undefined, false, undefined, this),
|
|
378
378
|
/* @__PURE__ */ jsxDEV2("div", {
|
|
@@ -402,7 +402,7 @@ function ProjectActionsModal({
|
|
|
402
402
|
"Are you sure you want to archive",
|
|
403
403
|
" ",
|
|
404
404
|
/* @__PURE__ */ jsxDEV2("span", {
|
|
405
|
-
className: "text-foreground
|
|
405
|
+
className: "font-medium text-foreground",
|
|
406
406
|
children: project.name
|
|
407
407
|
}, undefined, false, undefined, this),
|
|
408
408
|
"?"
|
|
@@ -413,7 +413,7 @@ function ProjectActionsModal({
|
|
|
413
413
|
children: "Archived projects can be restored later."
|
|
414
414
|
}, undefined, false, undefined, this),
|
|
415
415
|
error && /* @__PURE__ */ jsxDEV2("div", {
|
|
416
|
-
className: "bg-destructive/10
|
|
416
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
417
417
|
children: error
|
|
418
418
|
}, undefined, false, undefined, this),
|
|
419
419
|
/* @__PURE__ */ jsxDEV2("div", {
|
|
@@ -443,7 +443,7 @@ function ProjectActionsModal({
|
|
|
443
443
|
"Are you sure you want to delete",
|
|
444
444
|
" ",
|
|
445
445
|
/* @__PURE__ */ jsxDEV2("span", {
|
|
446
|
-
className: "text-foreground
|
|
446
|
+
className: "font-medium text-foreground",
|
|
447
447
|
children: project.name
|
|
448
448
|
}, undefined, false, undefined, this),
|
|
449
449
|
"?"
|
|
@@ -454,7 +454,7 @@ function ProjectActionsModal({
|
|
|
454
454
|
children: "This action cannot be undone."
|
|
455
455
|
}, undefined, false, undefined, this),
|
|
456
456
|
error && /* @__PURE__ */ jsxDEV2("div", {
|
|
457
|
-
className: "bg-destructive/10
|
|
457
|
+
className: "rounded-md bg-destructive/10 p-3 text-destructive text-sm",
|
|
458
458
|
children: error
|
|
459
459
|
}, undefined, false, undefined, this),
|
|
460
460
|
/* @__PURE__ */ jsxDEV2("div", {
|