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

feat(v2): impl initial create form modal feature, update Tile component #3048

Merged
merged 31 commits into from
Jan 14, 2022

Conversation

karrui
Copy link
Contributor

@karrui karrui commented Nov 15, 2021

Note that this PR builds on #3045 Merged

Problem

This PR adds the initial create form flow (without templates) to the workspace. Whilst doing so, updates the Tile component to be more extensible.

This PR does not include some features of form creation, such as

  • Form duplication
  • Create from use-template
  • Create from hardcoded templates

Closes #2788

Solution

Features:

  • feat: add CreateFormWizardContext to store create form states
  • feat: add CreateFormModal component, show the modal when create form button is clicked
  • feat: add useCreateFormMutations to handle form creation
  • feat(MailToLink): add MailToLink component for generating mailto links
  • feat: add SaveSecretKeyScreen component for storage mode forms

Improvements:

  • ref: reexport Tile subcomponents in Tile instead their own components
  • feat(WorkspaceService): use ApiService instead of axios
  • ref: extract form title validation rules to constant since logic is shared between form settings and form creation

Bug Fixes:

  • style(Tile): simplify styles
  • style(Badge): update styles according to design
  • feat: remove redundant props from custom Button component
  • fix: form title validation were passing even on empty strings

Before & After Screenshots

New stories have been added

Tests

Will add tests sooooooooooooooooooon

Deploy Notes

New dependencies:

  • dedent: Dedent strings due to extra tabs in code
  • file-saver: Trigger saving of files

@karrui karrui force-pushed the form-v2/feat/workspace/create-form-1 branch 2 times, most recently from 4df1e54 to 2089f51 Compare December 8, 2021 02:34
@karrui karrui force-pushed the form-v2/feat/workspace/layout-0 branch from cb48a24 to d51786c Compare December 8, 2021 02:55
@karrui karrui force-pushed the form-v2/feat/workspace/create-form-1 branch from 2089f51 to 51c9ef6 Compare December 8, 2021 02:55
@karrui karrui force-pushed the form-v2/feat/workspace/layout-0 branch from d51786c to 6e10117 Compare December 13, 2021 06:38
@karrui karrui force-pushed the form-v2/feat/workspace/create-form-1 branch from 51c9ef6 to 00a646e Compare December 13, 2021 06:38
@karrui karrui force-pushed the form-v2/feat/workspace/layout-0 branch from 6e10117 to 1be9742 Compare December 13, 2021 07:18
@karrui karrui force-pushed the form-v2/feat/workspace/create-form-1 branch from 00a646e to 94ec2dd Compare December 13, 2021 07:18
Base automatically changed from form-v2/feat/workspace/layout-0 to form-v2/develop December 15, 2021 03:32
only handle email mode responses for now, since storage mode screens are not in the app yet
used in settings page, and also when creating an email mode form
@karrui karrui force-pushed the form-v2/feat/workspace/create-form-1 branch from 94ec2dd to 0f4a98d Compare December 15, 2021 03:38
# Conflicts:
#	frontend/src/components/Tile/Tile.stories.tsx
#	frontend/src/theme/components/Button.ts
#	frontend/src/theme/components/Tile.ts
# Conflicts:
#	frontend/package-lock.json
#	frontend/package.json
@karrui karrui merged commit 021f252 into form-v2/develop Jan 14, 2022
@karrui karrui deleted the form-v2/feat/workspace/create-form-1 branch January 14, 2022 05:05
@justynoh justynoh mentioned this pull request Oct 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant