Skip to content

feat: s-form (and refactor c-form and django-cms-forms)#207

Merged
wesleyboar merged 19 commits intomainfrom
feat/s-form
Jul 31, 2023
Merged

feat: s-form (and refactor c-form and django-cms-forms)#207
wesleyboar merged 19 commits intomainfrom
feat/s-form

Conversation

@wesleyboar
Copy link
Member

@wesleyboar wesleyboar commented Jul 27, 2023

Overview / Changes

  1. Add s-form as a scope-version of c-form.
  2. Refactor c-form to style: c-form, s-form, django-cms-forms.
  3. Use one form template for all form demos.
  4. Added list spacing for <menu> for lists of interface elements.
  5. Renamed elements/form.cms.css to elements/form.css.
  6. Added elements/form.css to core-styles.base.css.
  7. Removed:
    • elements/form.cms.css
    • elements/django-cms-forms--errors-via-c-message.css

Related

Testing

  1. Verify all CMS form demos are identical and have CMS-styled errors:
  2. Verify all Portal form demos are identical and have Portal-styled errors:
  3. Verify all Default form demos are identical and have un-styled errors:
  4. Verify all form demos support toggling required fields:
    • Upon toggle off:
      • The first "(required)" field will become "(important)".
      • That first field will not be required to submit the form.
      • The second "(required)" field will remain "(required)".
        It is not a real field. It is JavaScript Captcha. It can not be un-required.
    • Upon toggle on:
      • The first "(important)" field will become "(required)".
      • That first field will be required to submit the form.
      • The second "(required)" field will remain "(required)".

UI

s-form.c-form.django-cms-forms.mov

@github-actions github-actions bot added the feature A new feature or replacement of existing feature label Jul 27, 2023
@wesleyboar wesleyboar added the minor A feature in backward-compatible manner label Jul 28, 2023
Also:
- fix minor space bugs
- fix new selector bugs
Removes `form.cms.css`.
- No problem if you already:
  - load `core-styles.cms.css`
  - load `core-styles.docs.css`

Adds form styles to `core-styles.base.css`.
- No problem if you already:
  - load `core-styles.cms.css`
  - load `core-styles.docs.css`
- Style influx if you:
  - load `core-styles.portal.css`
Make toggle-required-fields.js work on all forms, and document it.
They should incldue everythign they rely on. Now they do.

Notice core-styles/*.css changes are meerely removal of comments.
@wesleyboar wesleyboar changed the title feat: s-form feat: s-form (and refactor c-form and django-cms-forms) Jul 31, 2023
@wesleyboar wesleyboar marked this pull request as ready for review July 31, 2023 19:35
@wesleyboar wesleyboar merged commit aa240c4 into main Jul 31, 2023
@wesleyboar wesleyboar deleted the feat/s-form branch July 31, 2023 19:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature A new feature or replacement of existing feature minor A feature in backward-compatible manner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant