@actuate-media/cms-admin 0.78.0 → 0.79.1
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/CHANGELOG.md +17 -0
- package/dist/__tests__/lib/pages-service-fetch.test.js +10 -0
- package/dist/__tests__/lib/pages-service-fetch.test.js.map +1 -1
- package/dist/__tests__/lib/post-editor-service.test.js +35 -1
- package/dist/__tests__/lib/post-editor-service.test.js.map +1 -1
- package/dist/__tests__/views/form-editor.render.test.js +1 -0
- package/dist/__tests__/views/form-editor.render.test.js.map +1 -1
- package/dist/__tests__/views/forms-list.render.test.js +2 -0
- package/dist/__tests__/views/forms-list.render.test.js.map +1 -1
- package/dist/__tests__/views/redirects-pane.render.test.js +2 -0
- package/dist/__tests__/views/redirects-pane.render.test.js.map +1 -1
- package/dist/components/SEOPanel.d.ts +8 -0
- package/dist/components/SEOPanel.d.ts.map +1 -1
- package/dist/components/SEOPanel.js +7 -2
- package/dist/components/SEOPanel.js.map +1 -1
- package/dist/components/forms/FormSchemaPane.js +1 -1
- package/dist/components/forms/FormSchemaPane.js.map +1 -1
- package/dist/components/forms/NotificationsPanel.d.ts +4 -1
- package/dist/components/forms/NotificationsPanel.d.ts.map +1 -1
- package/dist/components/forms/NotificationsPanel.js +66 -12
- package/dist/components/forms/NotificationsPanel.js.map +1 -1
- package/dist/components/forms/ShortcodeGlossary.d.ts +5 -0
- package/dist/components/forms/ShortcodeGlossary.d.ts.map +1 -0
- package/dist/components/forms/ShortcodeGlossary.js +62 -0
- package/dist/components/forms/ShortcodeGlossary.js.map +1 -0
- package/dist/components/ui/ReauthDialog.d.ts +17 -0
- package/dist/components/ui/ReauthDialog.d.ts.map +1 -0
- package/dist/components/ui/ReauthDialog.js +34 -0
- package/dist/components/ui/ReauthDialog.js.map +1 -0
- package/dist/components/ui/index.d.ts +2 -0
- package/dist/components/ui/index.d.ts.map +1 -1
- package/dist/components/ui/index.js +1 -0
- package/dist/components/ui/index.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/forms-service.d.ts +9 -0
- package/dist/lib/forms-service.d.ts.map +1 -1
- package/dist/lib/forms-service.js +5 -0
- package/dist/lib/forms-service.js.map +1 -1
- package/dist/lib/pages-service.d.ts.map +1 -1
- package/dist/lib/pages-service.js +14 -15
- package/dist/lib/pages-service.js.map +1 -1
- package/dist/lib/post-editor-service.d.ts +6 -0
- package/dist/lib/post-editor-service.d.ts.map +1 -1
- package/dist/lib/post-editor-service.js +19 -1
- package/dist/lib/post-editor-service.js.map +1 -1
- package/dist/lib/seo-service.d.ts +4 -0
- package/dist/lib/seo-service.d.ts.map +1 -1
- package/dist/lib/seo-service.js +1 -0
- package/dist/lib/seo-service.js.map +1 -1
- package/dist/views/ApiKeys.d.ts.map +1 -1
- package/dist/views/ApiKeys.js +22 -23
- package/dist/views/ApiKeys.js.map +1 -1
- package/dist/views/DocumentEdit.d.ts.map +1 -1
- package/dist/views/DocumentEdit.js +5 -1
- package/dist/views/DocumentEdit.js.map +1 -1
- package/dist/views/FormEditor.js +1 -1
- package/dist/views/FormEditor.js.map +1 -1
- package/dist/views/seo/RedirectsTab.d.ts.map +1 -1
- package/dist/views/seo/RedirectsTab.js +3 -2
- package/dist/views/seo/RedirectsTab.js.map +1 -1
- package/dist/views/users/UserDetailDrawer.d.ts.map +1 -1
- package/dist/views/users/UserDetailDrawer.js +2 -30
- package/dist/views/users/UserDetailDrawer.js.map +1 -1
- package/package.json +3 -3
- package/src/__tests__/lib/pages-service-fetch.test.ts +11 -0
- package/src/__tests__/lib/post-editor-service.test.ts +46 -0
- package/src/__tests__/views/form-editor.render.test.tsx +1 -0
- package/src/__tests__/views/forms-list.render.test.tsx +2 -0
- package/src/__tests__/views/redirects-pane.render.test.tsx +2 -0
- package/src/components/SEOPanel.tsx +15 -3
- package/src/components/forms/FormSchemaPane.tsx +1 -1
- package/src/components/forms/NotificationsPanel.tsx +150 -20
- package/src/components/forms/ShortcodeGlossary.tsx +146 -0
- package/src/components/ui/ReauthDialog.tsx +93 -0
- package/src/components/ui/index.ts +2 -0
- package/src/index.ts +1 -1
- package/src/lib/forms-service.ts +12 -0
- package/src/lib/pages-service.ts +14 -15
- package/src/lib/post-editor-service.ts +17 -1
- package/src/lib/seo-service.ts +5 -0
- package/src/views/ApiKeys.tsx +48 -41
- package/src/views/DocumentEdit.tsx +5 -1
- package/src/views/FormEditor.tsx +1 -1
- package/src/views/seo/RedirectsTab.tsx +3 -1
- package/src/views/users/UserDetailDrawer.tsx +1 -76
|
@@ -39,6 +39,7 @@ import { Button } from '../../components/ui/Button.js'
|
|
|
39
39
|
import { Skeleton } from '../../components/ui/Skeleton.js'
|
|
40
40
|
import { EmptyState } from '../../components/ui/EmptyState.js'
|
|
41
41
|
import { ConfirmDialog } from '../../components/ui/ConfirmDialog.js'
|
|
42
|
+
import { ReauthDialog } from '../../components/ui/ReauthDialog.js'
|
|
42
43
|
|
|
43
44
|
// ---------------------------------------------------------------------------
|
|
44
45
|
// Types (mirror cms-core serialized shapes)
|
|
@@ -151,82 +152,6 @@ const STATUS_META: Record<UserDetail['status'], { dot: string; text: string; lab
|
|
|
151
152
|
},
|
|
152
153
|
}
|
|
153
154
|
|
|
154
|
-
// ---------------------------------------------------------------------------
|
|
155
|
-
// Reauth dialog
|
|
156
|
-
// ---------------------------------------------------------------------------
|
|
157
|
-
|
|
158
|
-
function ReauthDialog({
|
|
159
|
-
open,
|
|
160
|
-
onClose,
|
|
161
|
-
onSubmit,
|
|
162
|
-
}: {
|
|
163
|
-
open: boolean
|
|
164
|
-
onClose: () => void
|
|
165
|
-
onSubmit: (password: string) => Promise<void>
|
|
166
|
-
}) {
|
|
167
|
-
const [password, setPassword] = useState('')
|
|
168
|
-
const [busy, setBusy] = useState(false)
|
|
169
|
-
|
|
170
|
-
const submit = async () => {
|
|
171
|
-
if (!password || busy) return
|
|
172
|
-
setBusy(true)
|
|
173
|
-
try {
|
|
174
|
-
await onSubmit(password)
|
|
175
|
-
setPassword('')
|
|
176
|
-
} finally {
|
|
177
|
-
setBusy(false)
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
return (
|
|
182
|
-
<Modal
|
|
183
|
-
open={open}
|
|
184
|
-
onClose={() => {
|
|
185
|
-
setPassword('')
|
|
186
|
-
onClose()
|
|
187
|
-
}}
|
|
188
|
-
title="Confirm it's you"
|
|
189
|
-
actions={
|
|
190
|
-
<>
|
|
191
|
-
<Button
|
|
192
|
-
variant="ghost"
|
|
193
|
-
onClick={() => {
|
|
194
|
-
setPassword('')
|
|
195
|
-
onClose()
|
|
196
|
-
}}
|
|
197
|
-
>
|
|
198
|
-
Cancel
|
|
199
|
-
</Button>
|
|
200
|
-
<Button variant="primary" loading={busy} disabled={!password || busy} onClick={submit}>
|
|
201
|
-
Confirm
|
|
202
|
-
</Button>
|
|
203
|
-
</>
|
|
204
|
-
}
|
|
205
|
-
>
|
|
206
|
-
<p className="text-muted-foreground mb-3 text-sm">
|
|
207
|
-
This is a sensitive action. Re-enter your password to continue.
|
|
208
|
-
</p>
|
|
209
|
-
<label
|
|
210
|
-
htmlFor="reauth-password"
|
|
211
|
-
className="text-card-foreground mb-1 block text-sm font-medium"
|
|
212
|
-
>
|
|
213
|
-
Your password
|
|
214
|
-
</label>
|
|
215
|
-
<input
|
|
216
|
-
id="reauth-password"
|
|
217
|
-
type="password"
|
|
218
|
-
value={password}
|
|
219
|
-
onChange={(e) => setPassword(e.target.value)}
|
|
220
|
-
onKeyDown={(e) => {
|
|
221
|
-
if (e.key === 'Enter') submit()
|
|
222
|
-
}}
|
|
223
|
-
autoComplete="current-password"
|
|
224
|
-
className="border-border bg-input-background text-foreground focus:ring-brand w-full rounded-md border px-3 py-2 text-sm focus:ring-2 focus:outline-none"
|
|
225
|
-
/>
|
|
226
|
-
</Modal>
|
|
227
|
-
)
|
|
228
|
-
}
|
|
229
|
-
|
|
230
155
|
// ---------------------------------------------------------------------------
|
|
231
156
|
// Transfer content modal
|
|
232
157
|
// ---------------------------------------------------------------------------
|