Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor editing ux #110

Draft
wants to merge 88 commits into
base: newsetup
Choose a base branch
from
Draft
Changes from 1 commit
Commits
Show all changes
88 commits
Select commit Hold shift + click to select a range
98c787a
Update Brazilian Portuguese translations (#114)
ericof Sep 12, 2024
9dd726f
fix: Fix bug that form data can not be loaded for forms in accordions…
mbarde Sep 12, 2024
eb259a0
fix: reset otp on formdata reset (#116)
giuliaghisini Sep 12, 2024
7b945a8
chore: release v3.9.3
giuliaghisini Sep 12, 2024
9cda160
feat: email otp validation switchable per form (#119)
giuliaghisini Oct 2, 2024
afe2d11
chore: release v3.10.0
giuliaghisini Oct 2, 2024
3cdb14d
fix: always set static_text fields as not required
pnicolli Oct 3, 2024
caec8f9
chore: release v3.10.1
pnicolli Oct 3, 2024
fa124f7
New setup in place
sneridagh Jul 4, 2024
cb329d4
ESlint fixes and i18n
sneridagh Jul 4, 2024
75bac7e
Cypress example at least
sneridagh Jul 4, 2024
cade68d
Changelog
sneridagh Jul 4, 2024
a0fae84
Update package.json
sneridagh Jul 8, 2024
ea686e3
Remove dangling old package
sneridagh Jul 8, 2024
0a6f9ce
First unified version
sneridagh Jul 8, 2024
87cd861
Fix lint
sneridagh Jul 8, 2024
98a5096
Move backend CI from the addon
sneridagh Jul 9, 2024
b3433d9
Default dir
sneridagh Jul 9, 2024
2b48f75
Back to the old gha
sneridagh Jul 9, 2024
75ca67c
Use hatch
sneridagh Jul 11, 2024
1307e93
Fix some linting
sneridagh Jul 11, 2024
64c365a
Remove pre-commit
sneridagh Jul 11, 2024
3e52f8b
Fix linting errors
ericof Jul 15, 2024
214a9fd
Small fix on .editorconfig
ericof Jul 15, 2024
8ee64f5
Refactor tests
ericof Jul 15, 2024
ffb2759
Fix Docker image creation
ericof Jul 15, 2024
8a78b6e
Remove lingering files
sneridagh Jul 16, 2024
50b7ddc
Bring back docs folder
sneridagh Jul 16, 2024
cbcd545
Fix dependencies, remove pre-commit
ericof Jul 16, 2024
0dc681c
WIP
sneridagh Jul 26, 2024
7105fae
fixes
davisagli Aug 22, 2024
5c7b293
organize fieldsets better
davisagli Aug 26, 2024
0c6d955
fix FormDataStore for schemaForm
davisagli Aug 26, 2024
bbe25f0
server-side schema validation
davisagli Aug 26, 2024
8583e73
fix tests
davisagli Sep 10, 2024
151e144
Rearrange sidebar schema fields.
robgietema Sep 11, 2024
d4f245d
Set default values based on querystring.
robgietema Sep 11, 2024
3222d79
Add hidden field.
robgietema Sep 12, 2024
5dce485
Add static text field.
robgietema Sep 19, 2024
47c81d8
Rename service to schemaform-data to avoid colliding with old block
davisagli Sep 19, 2024
50ef79b
Refactor form processing into multiple processor subscribers
davisagli Sep 19, 2024
d8cc29f
Make captcha optional to facilitate testing
davisagli Sep 19, 2024
67c910e
fix handling of form data
davisagli Sep 20, 2024
f5b6ae9
progress on new email processor
davisagli Sep 23, 2024
0a192bd
Handle attachments
davisagli Sep 24, 2024
39f685c
Add confirmation email
davisagli Sep 24, 2024
99bd436
include sender name in email headers
davisagli Sep 24, 2024
46b4d0f
Set default fields.
robgietema Sep 30, 2024
45fcc6d
Render title and description.
robgietema Sep 30, 2024
1c634c8
get email template from registry
davisagli Oct 2, 2024
7e26e1b
Fix enter bug.
robgietema Oct 5, 2024
d765143
Filter data to be send.
robgietema Oct 5, 2024
94d4922
Fix translations.
robgietema Oct 5, 2024
98ed43d
Move captcha field to the end.
robgietema Oct 5, 2024
2d02233
Add thank you page.
robgietema Oct 5, 2024
e23e727
Add translations.
robgietema Oct 16, 2024
08d5b6c
Set text buttons.
robgietema Oct 16, 2024
4187e54
Add fields to thank you page.
robgietema Oct 29, 2024
2074115
Add email sender.
robgietema Oct 30, 2024
5900031
Fix thank you functionality.
robgietema Oct 30, 2024
e3482e3
Change labels.
robgietema Oct 30, 2024
216adfe
Add fixed attachment.
robgietema Oct 30, 2024
48b841d
Add translations.
robgietema Oct 30, 2024
808899f
Fix linting.
robgietema Nov 5, 2024
7982b4f
Add custom widgets wrappers.
robgietema Nov 13, 2024
6cd40a3
Add wrappers for custom forms.
robgietema Nov 18, 2024
cc05f56
Fix description styling.
robgietema Nov 25, 2024
3de4d74
Add default value to select box.
robgietema Nov 25, 2024
6a07150
Email and number widget fixes.
robgietema Nov 25, 2024
5e49edb
Update custom wrappers.
robgietema Nov 28, 2024
63e2c5f
Fix checkbox group.
robgietema Nov 30, 2024
5a413ae
Fix fieldset.
robgietema Dec 3, 2024
3bfd962
don't return attachments in the response after posting
davisagli Dec 5, 2024
71754f9
lint
davisagli Dec 5, 2024
510268e
Fix file widget in thank you page.
robgietema Dec 14, 2024
feddf65
Fix datetime wrapper values.
robgietema Dec 15, 2024
477f020
Add mail_templates vocabulary.
robgietema Dec 17, 2024
db614fa
Add mail_templates setting.
robgietema Dec 17, 2024
cb8695f
Fix required translation.
robgietema Dec 17, 2024
6fa401c
Add translations.
robgietema Dec 17, 2024
c9cd171
Fix clear date input.
robgietema Dec 17, 2024
e872328
Fix required for field wrappers.
robgietema Dec 17, 2024
1a499db
Support html in thank you page.
robgietema Dec 19, 2024
4944c2d
Fix placeholder for checkboxgroup.
robgietema Jan 14, 2025
b5fd610
Fix field types for number and time fields.
robgietema Jan 15, 2025
d6d47d6
Fix receipient field.
robgietema Jan 24, 2025
5fc8422
Fix BCC and fixed attachments.
robgietema Jan 24, 2025
4e2edbd
Add admin info to admin email.
robgietema Jan 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix Docker image creation
ericof authored and robgietema committed Nov 5, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit ffb2759271b6b7f65aefa05bf0bf61619e2e2200
29 changes: 0 additions & 29 deletions .github/workflows/backend.yml
Original file line number Diff line number Diff line change
@@ -139,32 +139,3 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
build-args: |
PLONE_VERSION=${{ needs.config.outputs.PLONE_VERSION }}

- name: Docker meta
id: meta-demo
uses: docker/metadata-action@v5
with:
images: |
${{ env.IMAGE_NAME_PREFIX }}-demo
labels: |
org.label-schema.docker.cmd=docker run -d -p 8080:8080 ${{ env.IMAGE_NAME_PREFIX }}-demo:latest
flavor:
latest=false
tags: |
type=ref,event=branch
type=sha
type=raw,value=latest,enable={{is_default_branch}}

- name: Build and push demo
uses: docker/build-push-action@v5
with:
platforms: linux/amd64
context: backend
file: backend/Dockerfile.demo
load: true
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta-demo.outputs.tags }}
labels: ${{ steps.meta-demo.outputs.labels }}
build-args: |
SEED=${{ github.run_id }}
IMAGE_TAG=${{ needs.config.outputs.BASE_TAG }}
15 changes: 6 additions & 9 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# syntax=docker/dockerfile:1
ARG PLONE_VERSION=6.0.11
FROM plone/server-builder:${PLONE_VERSION} as builder
FROM plone/server-builder:${PLONE_VERSION} AS builder

WORKDIR /app

@@ -12,24 +12,21 @@ COPY . src
# Install local requirements and pre-compile mo files
RUN <<EOT
set -e
bin/pip install mxdev uv
mv src/requirements-docker.txt src/requirements.txt
sed -i 's/-e .\[test\]/./g' src/mx.ini
bin/pip install mxdev uv hatch
cd /app/src
# remove potentially existing virtualenv from local build
rm -rf .venv
../bin/hatch build
../bin/mxdev -c mx.ini
../bin/uv pip install -r requirements-mxdev.txt
../bin/uv pip install dist/*.whl -c constraints-mxdev.txt
../bin/python /compile_mo.py
cd /app
rm -Rf src/
rm -Rf /app/src
EOT

FROM plone/server-prod-config:${PLONE_VERSION}

LABEL maintainer="Plone Foundation <collective@plone.org>" \
org.label-schema.name="volto-form-block-backend" \
org.label-schema.description="Project Title backend image." \
org.label-schema.description="Volto Form Block: Backend" \
org.label-schema.vendor="Plone Foundation"

# Copy /app from builder
3 changes: 0 additions & 3 deletions backend/Makefile
Original file line number Diff line number Diff line change
@@ -129,9 +129,6 @@ test-coverage: $(BIN_FOLDER)/pytest ## run tests with coverage
.PHONY: build-image
build-image: ## Build Docker Images
@DOCKER_BUILDKIT=1 docker build . -t $(IMAGE_NAME_PREFIX)-backend:$(IMAGE_TAG) -f Dockerfile --build-arg PLONE_VERSION=$(PLONE_VERSION)
@echo "$(GREEN)==> Building $(IMAGE_NAME_PREFIX)-demo:$(IMAGE_TAG) $(RESET)"
@DOCKER_BUILDKIT=1 docker build . --pull=false -t $(IMAGE_NAME_PREFIX)-demo:$(IMAGE_TAG) -f Dockerfile.demo --build-arg IMAGE_TAG=$(IMAGE_TAG) --build-arg SEED=$(SEED)


# Acceptance tests
.PHONY: acceptance-backend-start
31 changes: 31 additions & 0 deletions frontend/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# syntax=docker/dockerfile:1
ARG VOLTO_VERSION
# TODO: Replace with
# FROM plone/frontend-builder:${VOLTO_VERSION}
# when the main image is ready
FROM ghcr.io/kitconcept/frontend-builder:${VOLTO_VERSION} AS builder

COPY --chown=node packages/volto-form-block /app/packages/volto-form-block
COPY --chown=node volto.config.js /app/
COPY --chown=node package.json /app/package.json.temp

RUN --mount=type=cache,id=pnpm,target=/app/.pnpm-store,uid=1000 <<EOT
set -e
python3 -c "import json; data = json.load(open('package.json.temp')); deps = data['dependencies']; data['dependencies'].update(deps); json.dump(data, open('package.json', 'w'), indent=2)"
rm package.json.temp
pnpm install && pnpm build:deps
pnpm build
pnpm install --prod
EOT

# TODO: Replace with
# FROM plone/frontend-prod-config:${VOLTO_VERSION}
# when the main image is ready
FROM ghcr.io/kitconcept/frontend-prod-config:${VOLTO_VERSION}

LABEL maintainer="Plone Collective <collective@plone.org>" \
org.label-schema.name="ghcr.io/collective/volto-form-block-frontend" \
org.label-schema.description="Volto Form Block" \
org.label-schema.vendor="Plone Collective"

COPY --from=builder /app/ /app/