diff --git a/.husky/pre-commit b/.husky/pre-commit index f2cda7848b..8419615d07 100644 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,9 +1,14 @@ +export PATH="$HOME/.nvm/versions/node/v24.15.0/bin:$PATH" + set -e + +node -v npm -v +pnpm -v php -v -printf "\\n\\e[32m######### Linting Scripts #########\\e[0m\\n\\n" -npm run lint +printf "\n\e[32m######### Linting Scripts #########\e[0m\n\n" +pnpm lint -printf "\\n\\e[32m######### Running CS Fixer dry run #########\\e[0m\\n\\n" -composer run fix:dry-run || (printf \"\\e[41mCS Fixer found issues\\e[0m\\n\" && exit 1) +printf "\n\e[32m######### Running CS Fixer dry run #########\e[0m\n\n" +composer run fix:dry-run || (printf "\e[41mCS Fixer found issues\e[0m\n" && exit 1) \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 164a043a4d..345d0cb03d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Solspace Freeform Changelog +## 5.15.14 - Unreleased + +- TBD + ## 5.15.13 - 2026-05-18 ### Changed diff --git a/packages/client/config/freeform/freeform.config.ts b/packages/client/config/freeform/freeform.config.ts index 527a7b909e..98f89a26bb 100644 --- a/packages/client/config/freeform/freeform.config.ts +++ b/packages/client/config/freeform/freeform.config.ts @@ -61,6 +61,7 @@ type Config = { }; permissions: { integrations: Permission; + notifications: Permission; }; limitations: { items: null | Record; diff --git a/packages/client/src/app/components/form-controls/control-types/namespaced/notifications/notification-template/category/category.tsx b/packages/client/src/app/components/form-controls/control-types/namespaced/notifications/notification-template/category/category.tsx index 42ddad899f..1960716362 100644 --- a/packages/client/src/app/components/form-controls/control-types/namespaced/notifications/notification-template/category/category.tsx +++ b/packages/client/src/app/components/form-controls/control-types/namespaced/notifications/notification-template/category/category.tsx @@ -17,6 +17,7 @@ type Props = { title: string; templates: NotificationTemplate[]; canCreate?: boolean; + canEditGlobalTemplates?: boolean; openEditOnClick?: boolean; onClick: NotificationSelectHandler; onCreate?: () => void; @@ -27,6 +28,7 @@ export const Category: React.FC = ({ title, templates, canCreate, + canEditGlobalTemplates, openEditOnClick, onClick, onCreate, @@ -63,6 +65,7 @@ export const Category: React.FC = ({ = ({ active, + canEditGlobalTemplates, openEditOnClick, template, onClick, }) => { const { id, name } = template; + const { openModal: openModalFn } = useModal(); const queryClient = useQueryClient(); const openModal = useNotificationEditModal(); @@ -44,6 +47,34 @@ export const Item: React.FC = ({ > {name} + {!template.formId && canEditGlobalTemplates && ( + + + + )} + {!!template.formId && (