@firecms/core 3.4.0-canary.0ef7442 → 3.4.0-canary.1faa2a9
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/README.md +4 -0
- package/dist/components/EntityCollectionView/EntityCollectionView.d.ts +3 -2
- package/dist/components/EntityCollectionView/EntityCollectionViewActions.d.ts +3 -1
- package/dist/components/EntityCollectionView/EntityCollectionViewStartActions.d.ts +3 -1
- package/dist/components/ErrorBoundary.d.ts +1 -3
- package/dist/components/LicenseBanner.d.ts +23 -0
- package/dist/components/common/useDataSourceTableController.d.ts +4 -2
- package/dist/components/common/useTableSearchHelper.d.ts +3 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/contexts/LicenseStatusContext.d.ts +16 -0
- package/dist/core/EntityEditView.d.ts +2 -0
- package/dist/core/EntityEditViewFormActions.d.ts +1 -1
- package/dist/core/index.d.ts +1 -0
- package/dist/core/plugin_translations.d.ts +38 -0
- package/dist/core/pro_plugins.d.ts +40 -0
- package/dist/de-KtBROUvS.js +700 -0
- package/dist/de-KtBROUvS.js.map +1 -0
- package/dist/editor/extensions/Image.d.ts +11 -0
- package/dist/editor/index.d.ts +2 -1
- package/dist/editor/lazy_editor.d.ts +6 -0
- package/dist/editor-BSo_aS1I.js +4563 -0
- package/dist/editor-BSo_aS1I.js.map +1 -0
- package/dist/form/EntityForm.d.ts +2 -0
- package/dist/form/EntityFormActions.d.ts +2 -0
- package/dist/fr-BRFSBaVh.js +700 -0
- package/dist/fr-BRFSBaVh.js.map +1 -0
- package/dist/hi-DwCkga5X.js +700 -0
- package/dist/hi-DwCkga5X.js.map +1 -0
- package/dist/hooks/data/delete.d.ts +1 -1
- package/dist/hooks/data/useCollectionFetch.d.ts +1 -1
- package/dist/hooks/data/useEntityFetch.d.ts +4 -1
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/useLicenseStatus.d.ts +16 -0
- package/dist/hooks/useProjectLog.d.ts +11 -6
- package/dist/hooks/useTranslation.d.ts +1 -1
- package/dist/i18n/__tests__/FireCMSi18nProvider.test.d.ts +1 -0
- package/dist/i18n/__tests__/nested_provider_lifecycle.test.d.ts +1 -0
- package/dist/index.es.js +3503 -11244
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +8028 -7006
- package/dist/index.umd.js.map +1 -1
- package/dist/it-B2YGgDsx.js +700 -0
- package/dist/it-B2YGgDsx.js.map +1 -0
- package/dist/pl-BxHkywK8.js +702 -0
- package/dist/pl-BxHkywK8.js.map +1 -0
- package/dist/pt-q6UV4diT.js +702 -0
- package/dist/pt-q6UV4diT.js.map +1 -0
- package/dist/types/analytics.d.ts +1 -1
- package/dist/types/collections.d.ts +7 -0
- package/dist/types/datasource.d.ts +8 -0
- package/dist/types/entity_actions.d.ts +6 -0
- package/dist/types/entity_callbacks.d.ts +21 -0
- package/dist/types/firecms.d.ts +18 -1
- package/dist/types/firecms_context.d.ts +8 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/license.d.ts +54 -0
- package/dist/types/navigation.d.ts +34 -5
- package/dist/types/plugins.d.ts +22 -1
- package/dist/types/side_entity_controller.d.ts +3 -2
- package/dist/types/translations.d.ts +31 -2
- package/dist/util/date_fns_locales.d.ts +18 -0
- package/dist/util/entity_cache.d.ts +11 -0
- package/dist/util/index.d.ts +1 -0
- package/dist/util/lazy_eager.d.ts +3 -3
- package/dist/util/navigation_utils.d.ts +84 -2
- package/dist/util/parent_references_from_path.d.ts +15 -0
- package/dist/util/paths.d.ts +28 -0
- package/dist/util/permissions.d.ts +10 -4
- package/package.json +3 -3
- package/src/app/Scaffold.tsx +7 -0
- package/src/components/DeleteEntityDialog.tsx +2 -0
- package/src/components/EntityCollectionTable/EntityCollectionRowActions.tsx +2 -2
- package/src/components/EntityCollectionView/EntityCollectionBoardView.tsx +8 -0
- package/src/components/EntityCollectionView/EntityCollectionView.tsx +40 -15
- package/src/components/EntityCollectionView/EntityCollectionViewActions.tsx +6 -2
- package/src/components/EntityCollectionView/EntityCollectionViewStartActions.tsx +4 -0
- package/src/components/EntityCollectionView/useBoardDataController.tsx +7 -2
- package/src/components/EntityPreview.tsx +4 -1
- package/src/components/ErrorBoundary.tsx +12 -18
- package/src/components/LicenseBanner.tsx +209 -0
- package/src/components/ReferenceTable/ReferenceSelectionTable.tsx +8 -2
- package/src/components/common/default_entity_actions.tsx +22 -2
- package/src/components/common/useDataSourceTableController.tsx +26 -8
- package/src/components/common/useTableSearchHelper.ts +5 -0
- package/src/components/index.tsx +1 -0
- package/src/contexts/LicenseStatusContext.tsx +50 -0
- package/src/core/DefaultAppBar.tsx +28 -16
- package/src/core/EntityEditView.tsx +8 -12
- package/src/core/EntityEditViewFormActions.tsx +3 -2
- package/src/core/EntitySidePanel.tsx +6 -4
- package/src/core/FireCMS.tsx +73 -47
- package/src/core/SideDialogs.tsx +44 -1
- package/src/core/index.tsx +1 -0
- package/src/core/plugin_translations.ts +87 -0
- package/src/core/pro_plugins.ts +79 -0
- package/src/editor/components/SlashCommandMenu.tsx +4 -1
- package/src/editor/extensions/Image.ts +17 -1
- package/src/editor/hooks/useProseMirror.ts +5 -0
- package/src/editor/index.ts +11 -1
- package/src/editor/lazy_editor.tsx +33 -0
- package/src/form/EntityForm.tsx +22 -7
- package/src/form/EntityFormActions.tsx +2 -0
- package/src/hooks/data/delete.ts +8 -2
- package/src/hooks/data/save.ts +4 -1
- package/src/hooks/data/useCollectionFetch.tsx +9 -2
- package/src/hooks/data/useEntityFetch.tsx +19 -6
- package/src/hooks/index.tsx +2 -0
- package/src/hooks/useBuildNavigationController.tsx +70 -15
- package/src/hooks/useFireCMSContext.tsx +7 -3
- package/src/hooks/useLicenseStatus.tsx +32 -0
- package/src/hooks/useProjectLog.tsx +27 -9
- package/src/hooks/useResolvedNavigationFrom.tsx +1 -1
- package/src/hooks/useTranslation.ts +3 -1
- package/src/i18n/FireCMSi18nProvider.tsx +199 -25
- package/src/i18n/__tests__/FireCMSi18nProvider.test.tsx +91 -0
- package/src/i18n/__tests__/nested_provider_lifecycle.test.tsx +67 -0
- package/src/internal/useBuildDataSource.ts +13 -12
- package/src/internal/useBuildSideEntityController.tsx +13 -5
- package/src/locales/de.ts +16 -2
- package/src/locales/en.ts +18 -2
- package/src/locales/es.ts +16 -2
- package/src/locales/fr.ts +16 -2
- package/src/locales/hi.ts +16 -2
- package/src/locales/it.ts +16 -2
- package/src/locales/pl.ts +16 -2
- package/src/locales/pt.ts +16 -2
- package/src/preview/components/DatePreview.tsx +2 -4
- package/src/preview/components/ReferencePreview.tsx +7 -3
- package/src/routes/FireCMSRoute.tsx +9 -4
- package/src/types/analytics.ts +3 -0
- package/src/types/collections.ts +8 -0
- package/src/types/datasource.ts +8 -0
- package/src/types/entity_actions.tsx +6 -0
- package/src/types/entity_callbacks.ts +24 -0
- package/src/types/firecms.tsx +19 -1
- package/src/types/firecms_context.tsx +9 -0
- package/src/types/index.ts +1 -0
- package/src/types/license.ts +62 -0
- package/src/types/navigation.ts +35 -5
- package/src/types/plugins.tsx +23 -1
- package/src/types/side_entity_controller.tsx +3 -2
- package/src/types/translations.ts +31 -2
- package/src/util/date_fns_locales.ts +168 -0
- package/src/util/entity_cache.ts +18 -0
- package/src/util/index.ts +1 -0
- package/src/util/lazy_eager.tsx +30 -8
- package/src/util/navigation_from_path.ts +6 -1
- package/src/util/navigation_utils.ts +204 -2
- package/src/util/parent_references_from_path.ts +32 -1
- package/src/util/paths.ts +40 -3
- package/src/util/permissions.ts +22 -10
- package/src/util/useStorageUploadController.tsx +6 -1
package/src/locales/de.ts
CHANGED
|
@@ -65,8 +65,19 @@ export const de: FireCMSTranslations = {
|
|
|
65
65
|
select_from: "Aus {{name}} auswählen",
|
|
66
66
|
done: "Fertig",
|
|
67
67
|
log_out: "Abmelden",
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
license_trial_banner: "FireCMS PRO-Testphase: noch {{days}} Tage in Produktion.",
|
|
69
|
+
license_trial_banner_one: "FireCMS PRO-Testphase: noch {{days}} Tag in Produktion.",
|
|
70
|
+
license_expired_banner: "Ihre PRO-Testphase ist am {{date}} abgelaufen. PRO-Funktionen wie Schema-Editor, Import/Export und Verlauf sind pausiert; Ihre Daten und Sammlungen funktionieren weiterhin.",
|
|
71
|
+
license_expired_banner_undated: "Ihre PRO-Testphase ist abgelaufen. PRO-Funktionen wie Schema-Editor, Import/Export und Verlauf sind pausiert; Ihre Daten und Sammlungen funktionieren weiterhin.",
|
|
72
|
+
license_invalid_project_banner: "Dieser Lizenzschlüssel ist nicht mit dem Projekt {{projectId}} verknüpft. Bis dahin sind die PRO-Funktionen pausiert.",
|
|
73
|
+
license_invalid_project_banner_unnamed: "Dieser Lizenzschlüssel ist nicht mit diesem Projekt verknüpft. Bis dahin sind die PRO-Funktionen pausiert.",
|
|
74
|
+
license_over_quota_banner: "Diese Lizenz deckt {{licensed}} Projekte ab, verknüpft sind aber {{actual}}.",
|
|
75
|
+
license_over_quota_banner_one: "Diese Lizenz deckt {{licensed}} Projekt ab, verknüpft sind aber {{actual}}.",
|
|
76
|
+
license_get_license: "Lizenz erwerben",
|
|
77
|
+
license_update_license: "Lizenz aktualisieren",
|
|
78
|
+
license_add_project_to_license: "Zu Ihrer Lizenz hinzufügen",
|
|
79
|
+
pro_features_paused: "PRO-Funktionen pausiert",
|
|
80
|
+
user_management_paused_description: "Die Verwaltung von Benutzern und Rollen ist Teil von FireCMS PRO. Ihre bestehenden Benutzer und Rollen legen weiterhin fest, wer sich anmelden darf und was er tun kann. Bearbeiten können Sie sie wieder, sobald dieses Projekt eine Lizenz hat.",
|
|
70
81
|
column_cannot_be_edited: "Diese Spalte kann nicht direkt bearbeitet werden",
|
|
71
82
|
close: "Schließen",
|
|
72
83
|
unsaved_local_changes: "Ungespeicherte lokale Änderungen",
|
|
@@ -439,6 +450,7 @@ export const de: FireCMSTranslations = {
|
|
|
439
450
|
roles_menu: "Rollen",
|
|
440
451
|
project_settings: "Projekteinstellungen",
|
|
441
452
|
firestore_manager: "Firestore-Manager",
|
|
453
|
+
datatalk: "DataTalk",
|
|
442
454
|
manage_your_firestore_data: "Deine Firestore-Daten verwalten",
|
|
443
455
|
|
|
444
456
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -455,6 +467,7 @@ export const de: FireCMSTranslations = {
|
|
|
455
467
|
not_the_admin_panel: "nicht auf das Admin-Panel.",
|
|
456
468
|
join_our_newsletter: "Melden Sie sich für unseren Newsletter an. Kein Spam, nur wichtige Updates!",
|
|
457
469
|
by_signing_in_you_agree_to_our: "Mit der Anmeldung stimmen Sie unseren",
|
|
470
|
+
please_accept_the_terms_to_continue: "Bitte akzeptieren Sie die Nutzungsbedingungen, um fortzufahren",
|
|
458
471
|
terms_and_conditions: "Allgemeinen Geschäftsbedingungen",
|
|
459
472
|
and_our: "und unserer",
|
|
460
473
|
privacy_policy: "Datenschutzerklärung",
|
|
@@ -497,6 +510,7 @@ export const de: FireCMSTranslations = {
|
|
|
497
510
|
licensed_projects_lowercase: "lizenzierte projekte",
|
|
498
511
|
manage: "Verwalten",
|
|
499
512
|
update_payment_method: "Zahlungsmethode aktualisieren",
|
|
513
|
+
stripe_portal_error: "Stripe konnte nicht geöffnet werden: {{message}}",
|
|
500
514
|
your_firecms_cloud_projects: "Ihre FireCMS Cloud Projekte",
|
|
501
515
|
status_active: "Aktiv",
|
|
502
516
|
status_trialing: "Testphase",
|
package/src/locales/en.ts
CHANGED
|
@@ -73,8 +73,19 @@ export const en: FireCMSTranslations = {
|
|
|
73
73
|
select_from: "Select from {{name}}",
|
|
74
74
|
done: "Done",
|
|
75
75
|
log_out: "Log out",
|
|
76
|
-
|
|
77
|
-
|
|
76
|
+
license_trial_banner: "FireCMS PRO trial: {{days}} days left in production.",
|
|
77
|
+
license_trial_banner_one: "FireCMS PRO trial: {{days}} day left in production.",
|
|
78
|
+
license_expired_banner: "Your PRO trial ended on {{date}}. PRO features such as the schema editor, import/export and history are paused; your data and collections still work.",
|
|
79
|
+
license_expired_banner_undated: "Your PRO trial has ended. PRO features such as the schema editor, import/export and history are paused; your data and collections still work.",
|
|
80
|
+
license_invalid_project_banner: "This license key is not linked to project {{projectId}}. PRO features are paused until it is.",
|
|
81
|
+
license_invalid_project_banner_unnamed: "This license key is not linked to this project. PRO features are paused until it is.",
|
|
82
|
+
license_over_quota_banner: "This license covers {{licensed}} projects and {{actual}} are linked to it.",
|
|
83
|
+
license_over_quota_banner_one: "This license covers {{licensed}} project and {{actual}} are linked to it.",
|
|
84
|
+
license_get_license: "Get a license",
|
|
85
|
+
license_update_license: "Update your license",
|
|
86
|
+
license_add_project_to_license: "Add it to your license",
|
|
87
|
+
pro_features_paused: "PRO features paused",
|
|
88
|
+
user_management_paused_description: "Managing users and roles is part of FireCMS PRO. Your existing users and roles still decide who can sign in and what they can do, and you can edit them again once this project has a license.",
|
|
78
89
|
column_cannot_be_edited: "This column can't be edited directly",
|
|
79
90
|
close: "Close",
|
|
80
91
|
unsaved_local_changes: "Unsaved Local changes",
|
|
@@ -448,6 +459,9 @@ export const en: FireCMSTranslations = {
|
|
|
448
459
|
project_settings: "Project settings",
|
|
449
460
|
firestore_manager: "Firestore Manager",
|
|
450
461
|
manage_your_firestore_data: "Manage your Firestore data",
|
|
462
|
+
// A product name. It is a key rather than a literal so a locale that uses a
|
|
463
|
+
// different script can transliterate it; most will inherit this value.
|
|
464
|
+
datatalk: "DataTalk",
|
|
451
465
|
|
|
452
466
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
453
467
|
build_admin_panel_in_minutes: "Build Your Firebase Admin Panel in Minutes",
|
|
@@ -463,6 +477,7 @@ export const en: FireCMSTranslations = {
|
|
|
463
477
|
not_the_admin_panel: "not the admin panel.",
|
|
464
478
|
join_our_newsletter: "Join our newsletter. No spam, only important updates!",
|
|
465
479
|
by_signing_in_you_agree_to_our: "By signing in you agree to our",
|
|
480
|
+
please_accept_the_terms_to_continue: "Please accept the terms and conditions to continue",
|
|
466
481
|
terms_and_conditions: "Terms and Conditions",
|
|
467
482
|
and_our: "and our",
|
|
468
483
|
privacy_policy: "Privacy policy",
|
|
@@ -505,6 +520,7 @@ export const en: FireCMSTranslations = {
|
|
|
505
520
|
licensed_projects_lowercase: "licensed projects",
|
|
506
521
|
manage: "Manage",
|
|
507
522
|
update_payment_method: "Update payment method",
|
|
523
|
+
stripe_portal_error: "Could not open Stripe: {{message}}",
|
|
508
524
|
your_firecms_cloud_projects: "Your FireCMS Cloud projects",
|
|
509
525
|
status_active: "Active",
|
|
510
526
|
status_trialing: "Trialing",
|
package/src/locales/es.ts
CHANGED
|
@@ -73,8 +73,19 @@ export const es: FireCMSTranslations = {
|
|
|
73
73
|
select_from: "Seleccionar de {{name}}",
|
|
74
74
|
done: "Hecho",
|
|
75
75
|
log_out: "Cerrar sesión",
|
|
76
|
-
|
|
77
|
-
|
|
76
|
+
license_trial_banner: "Prueba de FireCMS PRO: quedan {{days}} días en producción.",
|
|
77
|
+
license_trial_banner_one: "Prueba de FireCMS PRO: queda {{days}} día en producción.",
|
|
78
|
+
license_expired_banner: "Tu prueba de PRO terminó el {{date}}. Las funciones PRO, como el editor de esquemas, la importación/exportación y el historial, están en pausa; tus datos y colecciones siguen funcionando.",
|
|
79
|
+
license_expired_banner_undated: "Tu prueba de PRO ha terminado. Las funciones PRO, como el editor de esquemas, la importación/exportación y el historial, están en pausa; tus datos y colecciones siguen funcionando.",
|
|
80
|
+
license_invalid_project_banner: "Esta clave de licencia no está vinculada al proyecto {{projectId}}. Las funciones PRO están en pausa hasta que lo esté.",
|
|
81
|
+
license_invalid_project_banner_unnamed: "Esta clave de licencia no está vinculada a este proyecto. Las funciones PRO están en pausa hasta que lo esté.",
|
|
82
|
+
license_over_quota_banner: "Esta licencia cubre {{licensed}} proyectos y tiene {{actual}} vinculados.",
|
|
83
|
+
license_over_quota_banner_one: "Esta licencia cubre {{licensed}} proyecto y tiene {{actual}} vinculados.",
|
|
84
|
+
license_get_license: "Obtener una licencia",
|
|
85
|
+
license_update_license: "Actualizar tu licencia",
|
|
86
|
+
license_add_project_to_license: "Añadirlo a tu licencia",
|
|
87
|
+
pro_features_paused: "Funciones PRO en pausa",
|
|
88
|
+
user_management_paused_description: "La gestión de usuarios y roles forma parte de FireCMS PRO. Tus usuarios y roles actuales siguen decidiendo quién puede iniciar sesión y qué puede hacer, y podrás editarlos de nuevo cuando este proyecto tenga una licencia.",
|
|
78
89
|
column_cannot_be_edited: "Esta columna no se puede editar directamente",
|
|
79
90
|
close: "Cerrar",
|
|
80
91
|
unsaved_local_changes: "Cambios locales sin guardar",
|
|
@@ -447,6 +458,7 @@ export const es: FireCMSTranslations = {
|
|
|
447
458
|
roles_menu: "Roles",
|
|
448
459
|
project_settings: "Ajustes del proyecto",
|
|
449
460
|
firestore_manager: "Gestor de Firestore",
|
|
461
|
+
datatalk: "DataTalk",
|
|
450
462
|
manage_your_firestore_data: "Gestiona tus datos de Firestore",
|
|
451
463
|
|
|
452
464
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -463,6 +475,7 @@ export const es: FireCMSTranslations = {
|
|
|
463
475
|
not_the_admin_panel: "no en el panel de administración.",
|
|
464
476
|
join_our_newsletter: "Únete a nuestro newsletter. ¡Sin spam, solo actualizaciones importantes!",
|
|
465
477
|
by_signing_in_you_agree_to_our: "Al iniciar sesión aceptas nuestros",
|
|
478
|
+
please_accept_the_terms_to_continue: "Acepta los términos y condiciones para continuar",
|
|
466
479
|
terms_and_conditions: "Términos y Condiciones",
|
|
467
480
|
and_our: "y nuestra",
|
|
468
481
|
privacy_policy: "Política de Privacidad",
|
|
@@ -505,6 +518,7 @@ export const es: FireCMSTranslations = {
|
|
|
505
518
|
licensed_projects_lowercase: "proyectos licenciados",
|
|
506
519
|
manage: "Administrar",
|
|
507
520
|
update_payment_method: "Actualizar método de pago",
|
|
521
|
+
stripe_portal_error: "No se pudo abrir Stripe: {{message}}",
|
|
508
522
|
your_firecms_cloud_projects: "Tus proyectos de FireCMS Cloud",
|
|
509
523
|
status_active: "Activo",
|
|
510
524
|
status_trialing: "En prueba",
|
package/src/locales/fr.ts
CHANGED
|
@@ -65,8 +65,19 @@ export const fr: FireCMSTranslations = {
|
|
|
65
65
|
select_from: "Sélectionner depuis {{name}}",
|
|
66
66
|
done: "Terminé",
|
|
67
67
|
log_out: "Se déconnecter",
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
license_trial_banner: "Essai de FireCMS PRO : {{days}} jours restants en production.",
|
|
69
|
+
license_trial_banner_one: "Essai de FireCMS PRO : {{days}} jour restant en production.",
|
|
70
|
+
license_expired_banner: "Votre essai PRO a pris fin le {{date}}. Les fonctions PRO, comme l'éditeur de schémas, l'import/export et l'historique, sont en pause ; vos données et vos collections fonctionnent toujours.",
|
|
71
|
+
license_expired_banner_undated: "Votre essai PRO a pris fin. Les fonctions PRO, comme l'éditeur de schémas, l'import/export et l'historique, sont en pause ; vos données et vos collections fonctionnent toujours.",
|
|
72
|
+
license_invalid_project_banner: "Cette clé de licence n'est pas associée au projet {{projectId}}. Les fonctionnalités PRO sont en pause d'ici là.",
|
|
73
|
+
license_invalid_project_banner_unnamed: "Cette clé de licence n'est pas associée à ce projet. Les fonctionnalités PRO sont en pause d'ici là.",
|
|
74
|
+
license_over_quota_banner: "Cette licence couvre {{licensed}} projets et {{actual}} y sont associés.",
|
|
75
|
+
license_over_quota_banner_one: "Cette licence couvre {{licensed}} projet et {{actual}} y sont associés.",
|
|
76
|
+
license_get_license: "Obtenir une licence",
|
|
77
|
+
license_update_license: "Mettre à jour votre licence",
|
|
78
|
+
license_add_project_to_license: "L'ajouter à votre licence",
|
|
79
|
+
pro_features_paused: "Fonctionnalités PRO en pause",
|
|
80
|
+
user_management_paused_description: "La gestion des utilisateurs et des rôles fait partie de FireCMS PRO. Vos utilisateurs et rôles existants déterminent toujours qui peut se connecter et ce qu'il peut faire, et vous pourrez à nouveau les modifier dès que ce projet aura une licence.",
|
|
70
81
|
column_cannot_be_edited: "Cette colonne ne peut pas être modifiée directement",
|
|
71
82
|
close: "Fermer",
|
|
72
83
|
unsaved_local_changes: "Modifications locales non enregistrées",
|
|
@@ -439,6 +450,7 @@ export const fr: FireCMSTranslations = {
|
|
|
439
450
|
roles_menu: "Rôles",
|
|
440
451
|
project_settings: "Paramètres du projet",
|
|
441
452
|
firestore_manager: "Gestionnaire Firestore",
|
|
453
|
+
datatalk: "DataTalk",
|
|
442
454
|
manage_your_firestore_data: "Gérez vos données Firestore",
|
|
443
455
|
|
|
444
456
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -455,6 +467,7 @@ export const fr: FireCMSTranslations = {
|
|
|
455
467
|
not_the_admin_panel: "pas sur le panneau d'administration.",
|
|
456
468
|
join_our_newsletter: "Inscrivez-vous à notre newsletter. Pas de spam, uniquement des mises à jour importantes !",
|
|
457
469
|
by_signing_in_you_agree_to_our: "En vous connectant, vous acceptez nos",
|
|
470
|
+
please_accept_the_terms_to_continue: "Veuillez accepter les conditions générales pour continuer",
|
|
458
471
|
terms_and_conditions: "Conditions générales",
|
|
459
472
|
and_our: "et notre",
|
|
460
473
|
privacy_policy: "Politique de confidentialité",
|
|
@@ -497,6 +510,7 @@ export const fr: FireCMSTranslations = {
|
|
|
497
510
|
licensed_projects_lowercase: "projets sous licence",
|
|
498
511
|
manage: "Gérer",
|
|
499
512
|
update_payment_method: "Mettre à jour le mode de paiement",
|
|
513
|
+
stripe_portal_error: "Impossible d'ouvrir Stripe : {{message}}",
|
|
500
514
|
your_firecms_cloud_projects: "Vos projets FireCMS Cloud",
|
|
501
515
|
status_active: "Actif",
|
|
502
516
|
status_trialing: "En période d'essai",
|
package/src/locales/hi.ts
CHANGED
|
@@ -65,8 +65,19 @@ export const hi: FireCMSTranslations = {
|
|
|
65
65
|
select_from: "{{name}} से चुनें",
|
|
66
66
|
done: "हो गया",
|
|
67
67
|
log_out: "लॉग आउट",
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
license_trial_banner: "FireCMS PRO ट्रायल: प्रोडक्शन में {{days}} दिन बाकी हैं।",
|
|
69
|
+
license_trial_banner_one: "FireCMS PRO ट्रायल: प्रोडक्शन में {{days}} दिन बाकी है।",
|
|
70
|
+
license_expired_banner: "आपका PRO ट्रायल {{date}} को समाप्त हो गया। स्कीमा एडिटर, इम्पोर्ट/एक्सपोर्ट और हिस्ट्री जैसी PRO सुविधाएँ रोक दी गई हैं; आपका डेटा और कलेक्शन्स काम करते रहेंगे।",
|
|
71
|
+
license_expired_banner_undated: "आपका PRO ट्रायल समाप्त हो गया है। स्कीमा एडिटर, इम्पोर्ट/एक्सपोर्ट और हिस्ट्री जैसी PRO सुविधाएँ रोक दी गई हैं; आपका डेटा और कलेक्शन्स काम करते रहेंगे।",
|
|
72
|
+
license_invalid_project_banner: "यह लाइसेंस कुंजी प्रोजेक्ट {{projectId}} से जुड़ी नहीं है। जब तक यह जुड़ नहीं जाती, PRO सुविधाएँ रुकी रहेंगी।",
|
|
73
|
+
license_invalid_project_banner_unnamed: "यह लाइसेंस कुंजी इस प्रोजेक्ट से जुड़ी नहीं है। जब तक यह जुड़ नहीं जाती, PRO सुविधाएँ रुकी रहेंगी।",
|
|
74
|
+
license_over_quota_banner: "यह लाइसेंस {{licensed}} प्रोजेक्ट कवर करता है, लेकिन इससे {{actual}} प्रोजेक्ट जुड़े हैं।",
|
|
75
|
+
license_over_quota_banner_one: "यह लाइसेंस {{licensed}} प्रोजेक्ट कवर करता है, लेकिन इससे {{actual}} प्रोजेक्ट जुड़े हैं।",
|
|
76
|
+
license_get_license: "लाइसेंस लें",
|
|
77
|
+
license_update_license: "अपना लाइसेंस अपडेट करें",
|
|
78
|
+
license_add_project_to_license: "इसे अपने लाइसेंस में जोड़ें",
|
|
79
|
+
pro_features_paused: "PRO सुविधाएँ रुकी हुई हैं",
|
|
80
|
+
user_management_paused_description: "यूज़र्स और रोल्स का प्रबंधन FireCMS PRO का हिस्सा है। आपके मौजूदा यूज़र्स और रोल्स अब भी तय करते हैं कि कौन साइन इन कर सकता है और क्या कर सकता है। इस प्रोजेक्ट को लाइसेंस मिलते ही आप उन्हें फिर से संपादित कर सकेंगे।",
|
|
70
81
|
column_cannot_be_edited: "इस कॉलम को सीधे संपादित नहीं किया जा सकता",
|
|
71
82
|
close: "बंद करें",
|
|
72
83
|
unsaved_local_changes: "सहेजे नहीं गए स्थानीय परिवर्तन",
|
|
@@ -439,6 +450,7 @@ export const hi: FireCMSTranslations = {
|
|
|
439
450
|
roles_menu: "भूमिकाएँ",
|
|
440
451
|
project_settings: "परियोजना सेटिंग",
|
|
441
452
|
firestore_manager: "Firestore मैनेजर",
|
|
453
|
+
datatalk: "DataTalk",
|
|
442
454
|
manage_your_firestore_data: "अपने Firestore डेटा का प्रबंधन करें",
|
|
443
455
|
|
|
444
456
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -455,6 +467,7 @@ export const hi: FireCMSTranslations = {
|
|
|
455
467
|
not_the_admin_panel: "व्यवस्थापक पैनल पर नहीं।",
|
|
456
468
|
join_our_newsletter: "हमारे न्यूज़लेटर से जुड़ें। बिना किसी स्पैम के, केवल महत्वपूर्ण अपडेट!",
|
|
457
469
|
by_signing_in_you_agree_to_our: "साइन इन करके आप हमारे नियमों और शर्तों से सहमत होते हैं",
|
|
470
|
+
please_accept_the_terms_to_continue: "जारी रखने के लिए कृपया नियम और शर्तें स्वीकार करें",
|
|
458
471
|
terms_and_conditions: "नियम और शर्तें",
|
|
459
472
|
and_our: "और हमारी गोपनीयता नीति",
|
|
460
473
|
privacy_policy: "गोपनीयता नीति",
|
|
@@ -497,6 +510,7 @@ export const hi: FireCMSTranslations = {
|
|
|
497
510
|
licensed_projects_lowercase: "लाइसेंस प्राप्त प्रोजेक्ट्स",
|
|
498
511
|
manage: "प्रबंधित करें",
|
|
499
512
|
update_payment_method: "भुगतान विधि अपडेट करें",
|
|
513
|
+
stripe_portal_error: "Stripe नहीं खुल सका: {{message}}",
|
|
500
514
|
your_firecms_cloud_projects: "आपके FireCMS Cloud प्रोजेक्ट्स",
|
|
501
515
|
status_active: "सक्रिय",
|
|
502
516
|
status_trialing: "परीक्षण (ट्रायल)",
|
package/src/locales/it.ts
CHANGED
|
@@ -65,8 +65,19 @@ export const it: FireCMSTranslations = {
|
|
|
65
65
|
select_from: "Seleziona da {{name}}",
|
|
66
66
|
done: "Fatto",
|
|
67
67
|
log_out: "Esci",
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
license_trial_banner: "Prova di FireCMS PRO: restano {{days}} giorni in produzione.",
|
|
69
|
+
license_trial_banner_one: "Prova di FireCMS PRO: resta {{days}} giorno in produzione.",
|
|
70
|
+
license_expired_banner: "La tua prova PRO è terminata il {{date}}. Le funzioni PRO, come l'editor degli schemi, l'importazione/esportazione e la cronologia, sono in pausa; i tuoi dati e le tue collezioni continuano a funzionare.",
|
|
71
|
+
license_expired_banner_undated: "La tua prova PRO è terminata. Le funzioni PRO, come l'editor degli schemi, l'importazione/esportazione e la cronologia, sono in pausa; i tuoi dati e le tue collezioni continuano a funzionare.",
|
|
72
|
+
license_invalid_project_banner: "Questa chiave di licenza non è collegata al progetto {{projectId}}. Le funzionalità PRO restano in pausa finché non lo sarà.",
|
|
73
|
+
license_invalid_project_banner_unnamed: "Questa chiave di licenza non è collegata a questo progetto. Le funzionalità PRO restano in pausa finché non lo sarà.",
|
|
74
|
+
license_over_quota_banner: "Questa licenza copre {{licensed}} progetti e ne ha {{actual}} collegati.",
|
|
75
|
+
license_over_quota_banner_one: "Questa licenza copre {{licensed}} progetto e ne ha {{actual}} collegati.",
|
|
76
|
+
license_get_license: "Ottieni una licenza",
|
|
77
|
+
license_update_license: "Aggiorna la tua licenza",
|
|
78
|
+
license_add_project_to_license: "Aggiungilo alla tua licenza",
|
|
79
|
+
pro_features_paused: "Funzionalità PRO in pausa",
|
|
80
|
+
user_management_paused_description: "La gestione di utenti e ruoli fa parte di FireCMS PRO. I tuoi utenti e ruoli attuali continuano a decidere chi può accedere e cosa può fare, e potrai modificarli di nuovo quando questo progetto avrà una licenza.",
|
|
70
81
|
column_cannot_be_edited: "Questa colonna non può essere modificata direttamente",
|
|
71
82
|
close: "Chiudi",
|
|
72
83
|
unsaved_local_changes: "Modifiche locali non salvate",
|
|
@@ -439,6 +450,7 @@ export const it: FireCMSTranslations = {
|
|
|
439
450
|
roles_menu: "Ruoli",
|
|
440
451
|
project_settings: "Impostazioni del progetto",
|
|
441
452
|
firestore_manager: "Gestore Firestore",
|
|
453
|
+
datatalk: "DataTalk",
|
|
442
454
|
manage_your_firestore_data: "Gestisci i tuoi dati Firestore",
|
|
443
455
|
|
|
444
456
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -455,6 +467,7 @@ export const it: FireCMSTranslations = {
|
|
|
455
467
|
not_the_admin_panel: "non sul pannello di amministrazione.",
|
|
456
468
|
join_our_newsletter: "Iscriviti alla nostra newsletter. Niente spam, solo aggiornamenti importanti!",
|
|
457
469
|
by_signing_in_you_agree_to_our: "Accedendo accetti i nostri",
|
|
470
|
+
please_accept_the_terms_to_continue: "Accetta i termini e le condizioni per continuare",
|
|
458
471
|
terms_and_conditions: "Termini e Condizioni",
|
|
459
472
|
and_our: "e la nostra",
|
|
460
473
|
privacy_policy: "Informativa sulla privacy",
|
|
@@ -497,6 +510,7 @@ export const it: FireCMSTranslations = {
|
|
|
497
510
|
licensed_projects_lowercase: "progetti con licenza",
|
|
498
511
|
manage: "Gestisci",
|
|
499
512
|
update_payment_method: "Aggiorna metodo di pagamento",
|
|
513
|
+
stripe_portal_error: "Impossibile aprire Stripe: {{message}}",
|
|
500
514
|
your_firecms_cloud_projects: "I tuoi progetti FireCMS Cloud",
|
|
501
515
|
status_active: "Attivo",
|
|
502
516
|
status_trialing: "In prova",
|
package/src/locales/pl.ts
CHANGED
|
@@ -65,8 +65,19 @@ export const pl: FireCMSTranslations = {
|
|
|
65
65
|
select_from: "Wybierz z {{name}}",
|
|
66
66
|
done: "Gotowe",
|
|
67
67
|
log_out: "Wyloguj się",
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
license_trial_banner: "Okres próbny FireCMS PRO w produkcji kończy się za {{days}} dni.",
|
|
69
|
+
license_trial_banner_one: "Okres próbny FireCMS PRO w produkcji kończy się za {{days}} dzień.",
|
|
70
|
+
license_expired_banner: "Twój okres próbny PRO zakończył się {{date}}. Funkcje PRO, takie jak edytor schematów, import/eksport i historia, są wstrzymane; Twoje dane i kolekcje nadal działają.",
|
|
71
|
+
license_expired_banner_undated: "Twój okres próbny PRO się zakończył. Funkcje PRO, takie jak edytor schematów, import/eksport i historia, są wstrzymane; Twoje dane i kolekcje nadal działają.",
|
|
72
|
+
license_invalid_project_banner: "Ten klucz licencyjny nie jest powiązany z projektem {{projectId}}. Do tego czasu funkcje PRO są wstrzymane.",
|
|
73
|
+
license_invalid_project_banner_unnamed: "Ten klucz licencyjny nie jest powiązany z tym projektem. Do tego czasu funkcje PRO są wstrzymane.",
|
|
74
|
+
license_over_quota_banner: "Liczba projektów objętych licencją: {{licensed}}, powiązanych z nią: {{actual}}.",
|
|
75
|
+
license_over_quota_banner_one: "Ta licencja obejmuje {{licensed}} projekt, a powiązanych z nią projektów jest: {{actual}}.",
|
|
76
|
+
license_get_license: "Kup licencję",
|
|
77
|
+
license_update_license: "Zaktualizuj licencję",
|
|
78
|
+
license_add_project_to_license: "Dodaj go do licencji",
|
|
79
|
+
pro_features_paused: "Funkcje PRO wstrzymane",
|
|
80
|
+
user_management_paused_description: "Zarządzanie użytkownikami i rolami jest częścią FireCMS PRO. Dotychczasowi użytkownicy i role nadal decydują o tym, kto może się zalogować i co może robić. Edytować je będzie można ponownie, gdy ten projekt otrzyma licencję.",
|
|
70
81
|
column_cannot_be_edited: "Ta kolumna nie może być edytowana bezpośrednio",
|
|
71
82
|
close: "Zamknij",
|
|
72
83
|
unsaved_local_changes: "Niezapisane zmiany lokalne",
|
|
@@ -439,6 +450,7 @@ export const pl: FireCMSTranslations = {
|
|
|
439
450
|
roles_menu: "Role",
|
|
440
451
|
project_settings: "Ustawienia projektu",
|
|
441
452
|
firestore_manager: "Menedżer Firestore",
|
|
453
|
+
datatalk: "DataTalk",
|
|
442
454
|
manage_your_firestore_data: "Zarządzaj danymi w Firestore",
|
|
443
455
|
|
|
444
456
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -455,6 +467,7 @@ export const pl: FireCMSTranslations = {
|
|
|
455
467
|
not_the_admin_panel: "a nie na panelu administracyjnym.",
|
|
456
468
|
join_our_newsletter: "Dołącz do naszego newslettera. Bez spamu, tylko ważne aktualizacje!",
|
|
457
469
|
by_signing_in_you_agree_to_our: "Logując się, akceptujesz nasz",
|
|
470
|
+
please_accept_the_terms_to_continue: "Zaakceptuj regulamin, aby kontynuować",
|
|
458
471
|
terms_and_conditions: "Regulamin",
|
|
459
472
|
and_our: "oraz naszą",
|
|
460
473
|
privacy_policy: "Politykę prywatności",
|
|
@@ -497,6 +510,7 @@ export const pl: FireCMSTranslations = {
|
|
|
497
510
|
licensed_projects_lowercase: "licencjonowanych projektów",
|
|
498
511
|
manage: "Zarządzaj",
|
|
499
512
|
update_payment_method: "Zaktualizuj metodę płatności",
|
|
513
|
+
stripe_portal_error: "Nie udało się otworzyć Stripe: {{message}}",
|
|
500
514
|
your_firecms_cloud_projects: "Twoje projekty FireCMS Cloud",
|
|
501
515
|
status_active: "Aktywna",
|
|
502
516
|
status_trialing: "Okres próbny",
|
package/src/locales/pt.ts
CHANGED
|
@@ -70,8 +70,19 @@ export const pt: FireCMSTranslations = {
|
|
|
70
70
|
select_from: "Selecionar de {{name}}",
|
|
71
71
|
done: "Concluído",
|
|
72
72
|
log_out: "Terminar sessão",
|
|
73
|
-
|
|
74
|
-
|
|
73
|
+
license_trial_banner: "Avaliação do FireCMS PRO: faltam {{days}} dias em produção.",
|
|
74
|
+
license_trial_banner_one: "Avaliação do FireCMS PRO: falta {{days}} dia em produção.",
|
|
75
|
+
license_expired_banner: "A sua avaliação PRO terminou a {{date}}. As funcionalidades PRO, como o editor de esquemas, a importação/exportação e o histórico, estão em pausa; os seus dados e coleções continuam a funcionar.",
|
|
76
|
+
license_expired_banner_undated: "A sua avaliação PRO terminou. As funcionalidades PRO, como o editor de esquemas, a importação/exportação e o histórico, estão em pausa; os seus dados e coleções continuam a funcionar.",
|
|
77
|
+
license_invalid_project_banner: "Esta chave de licença não está associada ao projeto {{projectId}}. As funcionalidades PRO ficam em pausa até que esteja.",
|
|
78
|
+
license_invalid_project_banner_unnamed: "Esta chave de licença não está associada a este projeto. As funcionalidades PRO ficam em pausa até que esteja.",
|
|
79
|
+
license_over_quota_banner: "Esta licença cobre {{licensed}} projetos e tem {{actual}} associados.",
|
|
80
|
+
license_over_quota_banner_one: "Esta licença cobre {{licensed}} projeto e tem {{actual}} associados.",
|
|
81
|
+
license_get_license: "Obter uma licença",
|
|
82
|
+
license_update_license: "Atualizar a sua licença",
|
|
83
|
+
license_add_project_to_license: "Adicioná-lo à sua licença",
|
|
84
|
+
pro_features_paused: "Funcionalidades PRO em pausa",
|
|
85
|
+
user_management_paused_description: "A gestão de utilizadores e funções faz parte do FireCMS PRO. Os seus utilizadores e funções atuais continuam a decidir quem pode iniciar sessão e o que pode fazer, e poderá voltar a editá-los assim que este projeto tiver uma licença.",
|
|
75
86
|
column_cannot_be_edited: "Esta coluna não pode ser editada diretamente",
|
|
76
87
|
close: "Fechar",
|
|
77
88
|
unsaved_local_changes: "Alterações locais não guardadas",
|
|
@@ -444,6 +455,7 @@ export const pt: FireCMSTranslations = {
|
|
|
444
455
|
roles_menu: "Funções",
|
|
445
456
|
project_settings: "Definições do projeto",
|
|
446
457
|
firestore_manager: "Gerenciador do Firestore",
|
|
458
|
+
datatalk: "DataTalk",
|
|
447
459
|
manage_your_firestore_data: "Gerencie os seus dados do Firestore",
|
|
448
460
|
|
|
449
461
|
// ─── FireCMS Cloud Login ──────────────────────────────────────
|
|
@@ -460,6 +472,7 @@ export const pt: FireCMSTranslations = {
|
|
|
460
472
|
not_the_admin_panel: "não no painel de administração.",
|
|
461
473
|
join_our_newsletter: "Subscreva a nossa newsletter. Sem spam, apenas atualizações importantes!",
|
|
462
474
|
by_signing_in_you_agree_to_our: "Ao iniciar sessão, concorda com os nossos",
|
|
475
|
+
please_accept_the_terms_to_continue: "Aceite os termos e condições para continuar",
|
|
463
476
|
terms_and_conditions: "Termos e Condições",
|
|
464
477
|
and_our: "e a nossa",
|
|
465
478
|
privacy_policy: "Política de privacidade",
|
|
@@ -502,6 +515,7 @@ export const pt: FireCMSTranslations = {
|
|
|
502
515
|
licensed_projects_lowercase: "projetos licenciados",
|
|
503
516
|
manage: "Gerir",
|
|
504
517
|
update_payment_method: "Atualizar método de pagamento",
|
|
518
|
+
stripe_portal_error: "Não foi possível abrir o Stripe: {{message}}",
|
|
505
519
|
your_firecms_cloud_projects: "Os seus projetos FireCMS Cloud",
|
|
506
520
|
status_active: "Ativo",
|
|
507
521
|
status_trialing: "Em avaliação",
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
|
|
3
3
|
import { format } from "date-fns";
|
|
4
|
-
import * as locales from "date-fns/locale";
|
|
5
4
|
import { useCustomizationController } from "../../hooks";
|
|
6
|
-
import { defaultDateFormat } from "../../util";
|
|
5
|
+
import { defaultDateFormat, useDateFnsLocale } from "../../util";
|
|
7
6
|
|
|
8
7
|
export interface DatePreviewProps {
|
|
9
8
|
date: Date;
|
|
@@ -28,8 +27,7 @@ export function DatePreview({
|
|
|
28
27
|
}: DatePreviewProps): React.ReactElement {
|
|
29
28
|
|
|
30
29
|
const customizationController = useCustomizationController();
|
|
31
|
-
|
|
32
|
-
const dateUtilsLocale = customizationController?.locale ? locales[customizationController?.locale] : undefined;
|
|
30
|
+
const dateUtilsLocale = useDateFnsLocale(customizationController?.locale);
|
|
33
31
|
|
|
34
32
|
if (!date) {
|
|
35
33
|
return <></>;
|
|
@@ -7,6 +7,7 @@ import { Skeleton } from "@firecms/ui";
|
|
|
7
7
|
import { ErrorBoundary, ErrorView } from "../../components";
|
|
8
8
|
import { EntityPreview, EntityPreviewContainer } from "../../components/EntityPreview";
|
|
9
9
|
import { jsonStringifyReplacer } from "../../util/objects";
|
|
10
|
+
import { entityCacheKey } from "../../util/entity_cache";
|
|
10
11
|
|
|
11
12
|
export type ReferencePreviewProps = {
|
|
12
13
|
disabled?: boolean;
|
|
@@ -53,7 +54,7 @@ function ReferencePreviewInternal({
|
|
|
53
54
|
|
|
54
55
|
const navigationController = useNavigationController();
|
|
55
56
|
|
|
56
|
-
const collection = navigationController.getCollection(reference.path);
|
|
57
|
+
const collection = navigationController.getCollection(reference.path, false, reference.pathSegments);
|
|
57
58
|
if (!collection) {
|
|
58
59
|
if (customizationController.components?.missingReference) {
|
|
59
60
|
return <customizationController.components.missingReference path={reference.path}/>;
|
|
@@ -99,16 +100,19 @@ function ReferencePreviewExisting<M extends Record<string, any> = any>({
|
|
|
99
100
|
dataLoadingError
|
|
100
101
|
} = useEntityFetch({
|
|
101
102
|
path: reference.path,
|
|
103
|
+
// References carry the segments of the collection they point at, when the code that
|
|
104
|
+
// built them knew them (see getReferenceFrom).
|
|
105
|
+
pathSegments: reference.pathSegments,
|
|
102
106
|
entityId: reference.id,
|
|
103
107
|
collection,
|
|
104
108
|
useCache: true
|
|
105
109
|
});
|
|
106
110
|
|
|
107
111
|
if (entity) {
|
|
108
|
-
referencesCache.set(reference.
|
|
112
|
+
referencesCache.set(entityCacheKey(reference.path, reference.id), entity);
|
|
109
113
|
}
|
|
110
114
|
|
|
111
|
-
const usedEntity = entity ?? referencesCache.get(reference.
|
|
115
|
+
const usedEntity = entity ?? referencesCache.get(entityCacheKey(reference.path, reference.id));
|
|
112
116
|
|
|
113
117
|
let body: React.ReactNode;
|
|
114
118
|
|
|
@@ -90,7 +90,7 @@ export function FireCMSRoute() {
|
|
|
90
90
|
let collection: EntityCollection<any> | undefined;
|
|
91
91
|
collection = navigation.getCollectionById(navigationEntries[0].id);
|
|
92
92
|
if (!collection)
|
|
93
|
-
collection = navigation.getCollection(navigationEntries[0].path);
|
|
93
|
+
collection = navigation.getCollection(navigationEntries[0].path, false, navigationEntries[0].pathSegments);
|
|
94
94
|
if (!collection)
|
|
95
95
|
return null;
|
|
96
96
|
return <React.Suspense fallback={null}>
|
|
@@ -114,7 +114,7 @@ export function FireCMSRoute() {
|
|
|
114
114
|
const firstEntry = navigationEntries[0] as NavigationViewCollectionInternal<any>;
|
|
115
115
|
collection = navigation.getCollectionById(firstEntry.id);
|
|
116
116
|
if (!collection)
|
|
117
|
-
collection = navigation.getCollection(firstEntry.path);
|
|
117
|
+
collection = navigation.getCollection(firstEntry.path, false, firstEntry.pathSegments);
|
|
118
118
|
if (!collection)
|
|
119
119
|
return null;
|
|
120
120
|
return <React.Suspense fallback={null}>
|
|
@@ -186,6 +186,8 @@ function EntityFullScreenRoute({
|
|
|
186
186
|
const urlTab = getSelectedTabFromUrl(isNew, lastCustomView);
|
|
187
187
|
const [selectedTab, setSelectedTab] = useState<string | undefined>(urlTab);
|
|
188
188
|
|
|
189
|
+
// `navigationPath` comes from the URL, where entity ids are still escaped (see
|
|
190
|
+
// encodeEntityId), so splitting it on "/" inside is correct and no segments are needed.
|
|
189
191
|
const parentCollectionIds = navigation.getParentCollectionIds(navigationPath);
|
|
190
192
|
useEffect(() => {
|
|
191
193
|
if (urlTab !== selectedTab) {
|
|
@@ -250,14 +252,17 @@ function EntityFullScreenRoute({
|
|
|
250
252
|
// `fullIdPath` is used downstream to build URLs, so it carries the escaped chain;
|
|
251
253
|
// `collectionPath` addresses the datasource, so it is resolved from the raw one.
|
|
252
254
|
const fullIdPath = isNew ? lastCollectionEntry!.fullPath : (parentCollectionEntry?.fullPath ?? lastEntityEntry!.fullPath);
|
|
253
|
-
|
|
255
|
+
// The navigation entries know the real segment boundaries, so the path is resolved
|
|
256
|
+
// from them rather than re-parsed out of the flattened string.
|
|
257
|
+
const pathSegments = isNew ? lastCollectionEntry!.pathSegments : lastEntityEntry!.pathSegments;
|
|
258
|
+
const collectionPath = navigation.resolveIdsFrom(isNew ? lastCollectionEntry!.path : lastEntityEntry!.path, pathSegments);
|
|
254
259
|
return <>
|
|
255
260
|
<React.Suspense fallback={null}>
|
|
256
261
|
<EntityEditView
|
|
257
262
|
key={collection.id + "_" + (isNew ? "new" : (isCopy ? entityId + "_copy" : entityId))}
|
|
258
263
|
entityId={isNew ? undefined : entityId}
|
|
259
264
|
fullIdPath={fullIdPath}
|
|
260
|
-
pathSegments={
|
|
265
|
+
pathSegments={pathSegments}
|
|
261
266
|
collection={collection}
|
|
262
267
|
layout={"full_screen"}
|
|
263
268
|
path={collectionPath}
|
package/src/types/analytics.ts
CHANGED
package/src/types/collections.ts
CHANGED
|
@@ -497,6 +497,14 @@ export interface CollectionActionsProps<M extends Record<string, any> = any, USE
|
|
|
497
497
|
*/
|
|
498
498
|
path: string;
|
|
499
499
|
|
|
500
|
+
/**
|
|
501
|
+
* `path` split at its real segment boundaries, e.g. `["nodes", "node/42", "edges"]`.
|
|
502
|
+
*
|
|
503
|
+
* Optional, and never derived by splitting `path` — a parent entity id may itself
|
|
504
|
+
* contain "/". Absent means "not known here", not "no slashes".
|
|
505
|
+
*/
|
|
506
|
+
pathSegments?: string[];
|
|
507
|
+
|
|
500
508
|
/**
|
|
501
509
|
* Path of the last collection, like `addresses`
|
|
502
510
|
*/
|
package/src/types/datasource.ts
CHANGED
|
@@ -283,6 +283,10 @@ export interface DataSource {
|
|
|
283
283
|
initTextSearch?: (props: {
|
|
284
284
|
context: FireCMSContext,
|
|
285
285
|
path: string,
|
|
286
|
+
/**
|
|
287
|
+
* `path` split at its real segment boundaries, when known. Never derived from `path`.
|
|
288
|
+
*/
|
|
289
|
+
pathSegments?: string[],
|
|
286
290
|
collection: EntityCollection,
|
|
287
291
|
parentCollectionIds?: string[]
|
|
288
292
|
}) => Promise<boolean>;
|
|
@@ -453,6 +457,10 @@ export interface DataSourceDelegate {
|
|
|
453
457
|
initTextSearch?: (props: {
|
|
454
458
|
context: FireCMSContext,
|
|
455
459
|
path: string,
|
|
460
|
+
/**
|
|
461
|
+
* `path` split at its real segment boundaries, when known. Never derived from `path`.
|
|
462
|
+
*/
|
|
463
|
+
pathSegments?: string[],
|
|
456
464
|
databaseId?: string,
|
|
457
465
|
collection: EntityCollection,
|
|
458
466
|
parentCollectionIds?: string[]
|
|
@@ -65,6 +65,12 @@ export type EntityActionClickProps<M extends object, USER extends User = User> =
|
|
|
65
65
|
context: FireCMSContext<USER>;
|
|
66
66
|
|
|
67
67
|
fullPath?: string;
|
|
68
|
+
/**
|
|
69
|
+
* `fullPath` split at its real segment boundaries, e.g. `["nodes", "node/42", "edges"]`,
|
|
70
|
+
* when the caller knows them. Absent means "not known here" — never derived from
|
|
71
|
+
* `fullPath`, since a parent id may itself contain "/".
|
|
72
|
+
*/
|
|
73
|
+
pathSegments?: string[];
|
|
68
74
|
fullIdPath?: string;
|
|
69
75
|
collection?: EntityCollection<M>;
|
|
70
76
|
|
|
@@ -86,6 +86,14 @@ export interface EntityOnFetchProps<M extends Record<string, any> = any, USER ex
|
|
|
86
86
|
*/
|
|
87
87
|
path: string;
|
|
88
88
|
|
|
89
|
+
/**
|
|
90
|
+
* `path` split at its real segment boundaries, e.g. `["nodes", "node/42", "edges"]`.
|
|
91
|
+
*
|
|
92
|
+
* Optional, and never derived by splitting `path` — a parent entity id may itself
|
|
93
|
+
* contain "/". Absent means "not known here", not "no slashes".
|
|
94
|
+
*/
|
|
95
|
+
pathSegments?: string[];
|
|
96
|
+
|
|
89
97
|
/**
|
|
90
98
|
* Fetched entity
|
|
91
99
|
*/
|
|
@@ -133,6 +141,14 @@ export interface EntityOnSaveProps<M extends Record<string, any> = any, USER ext
|
|
|
133
141
|
*/
|
|
134
142
|
path: string;
|
|
135
143
|
|
|
144
|
+
/**
|
|
145
|
+
* `path` split at its real segment boundaries, e.g. `["nodes", "node/42", "edges"]`.
|
|
146
|
+
*
|
|
147
|
+
* Optional, and never derived by splitting `path` — a parent entity id may itself
|
|
148
|
+
* contain "/". Absent means "not known here", not "no slashes".
|
|
149
|
+
*/
|
|
150
|
+
pathSegments?: string[];
|
|
151
|
+
|
|
136
152
|
/**
|
|
137
153
|
* Full path where this entity is being saved, with alias resolved
|
|
138
154
|
*/
|
|
@@ -180,6 +196,14 @@ export interface EntityOnDeleteProps<M extends Record<string, any> = any, USER e
|
|
|
180
196
|
*/
|
|
181
197
|
path: string;
|
|
182
198
|
|
|
199
|
+
/**
|
|
200
|
+
* `path` split at its real segment boundaries, e.g. `["nodes", "node/42", "edges"]`.
|
|
201
|
+
*
|
|
202
|
+
* Optional, and never derived by splitting `path` — a parent entity id may itself
|
|
203
|
+
* contain "/". Absent means "not known here", not "no slashes".
|
|
204
|
+
*/
|
|
205
|
+
pathSegments?: string[];
|
|
206
|
+
|
|
183
207
|
/**
|
|
184
208
|
* Deleted entity id
|
|
185
209
|
*/
|
package/src/types/firecms.tsx
CHANGED
|
@@ -70,10 +70,28 @@ export type FireCMSProps<USER extends User> = {
|
|
|
70
70
|
}) => React.ReactNode;
|
|
71
71
|
|
|
72
72
|
/**
|
|
73
|
-
*
|
|
73
|
+
* Your FireCMS PRO license key. It is checked against
|
|
74
|
+
* `https://api.firecms.co/access_log` when a user signs in.
|
|
74
75
|
*/
|
|
75
76
|
apiKey?: string;
|
|
76
77
|
|
|
78
|
+
/**
|
|
79
|
+
* On sign-in FireCMS sends one request to `https://api.firecms.co/access_log`
|
|
80
|
+
* with the user's ID token (which carries the Firebase project id, the uid
|
|
81
|
+
* and the email), the user's email, the datasource key and the keys of the
|
|
82
|
+
* mounted plugins; the browser adds the page's referrer. It is how the
|
|
83
|
+
* FireCMS PRO license and trial are checked. No database credentials or
|
|
84
|
+
* content are sent.
|
|
85
|
+
*
|
|
86
|
+
* Set to `false` to skip that request. This only takes effect when the
|
|
87
|
+
* app has no `apiKey` and mounts no PRO plugin (collection editor, user
|
|
88
|
+
* management, import/export, entity history, data enhancement, DataTalk):
|
|
89
|
+
* otherwise the request is the license check and is always sent.
|
|
90
|
+
*
|
|
91
|
+
* Defaults to `true`.
|
|
92
|
+
*/
|
|
93
|
+
telemetry?: boolean;
|
|
94
|
+
|
|
77
95
|
/**
|
|
78
96
|
* Record of custom form fields to be used in the CMS.
|
|
79
97
|
* You can use the key to reference the custom field in
|