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

Divider Support on new editor content #31066

Closed
Tracked by #25445
nicobytes opened this issue Jan 6, 2025 · 1 comment · Fixed by #31064
Closed
Tracked by #25445

Divider Support on new editor content #31066

nicobytes opened this issue Jan 6, 2025 · 1 comment · Fixed by #31064

Comments

@nicobytes
Copy link
Contributor

Parent Issue

No response

Task

Ensure proper support for the divider feature within the new content editor.

Current behavior:

MacBook Pro-1736191191675

On old content editor:

MacBook Pro-1736191234940

Proposed Objective

Core Features

Proposed Priority

Priority 2 - Important

Acceptance Criteria

No response

External Links... Slack Conversations, Support Tickets, Figma Designs, etc.

No response

Assumptions & Initiation Needs

No response

Quality Assurance Notes & Workarounds

No response

Sub-Tasks & Estimates

No response

@nicobytes
Copy link
Contributor Author

nicobytes commented Jan 6, 2025

QA notes:

Steps to reproduce:

  1. Enable the new editor content by setting DOT_FEATURE_FLAG_NEW_EDIT_PAGE and DOT_CONTENT_EDITOR2_ENABLED to true.
  2. Create a new content type: navigate to Content Model > Content Type > Create Content.
  3. Enable the Edit Content Beta feature.
  4. Open the content created previously.
  5. Add a divider field.

Screenshots

Original Updated
MacBook Pro-1736191191675 MacBook Pro-1736191805768

github-merge-queue bot pushed a commit that referenced this issue Jan 7, 2025
### Parent Issue

#31066

### Proposed Changes

This pull request introduces a new `LINE_DIVIDER` field type to the
`dot-edit-content-field` component and updates the project
configuration. The most important changes include the addition of the
`LINE_DIVIDER` field type, updates to the HTML template to use
`ngTemplateOutlet`, and modifications to the TypeScript configuration.

### Addition of `LINE_DIVIDER` Field Type:

*
[`core-web/libs/edit-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.html`](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR1-R90):
Added `LINE_DIVIDER` case and updated other field cases to use
`ngTemplateOutlet` for the label template.
[[1]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR1-R90)
[[2]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR100)
[[3]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR109)
[[4]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR119-R127)
[[5]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR136-R144)
[[6]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR153)
[[7]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR162)
[[8]](diffhunk://#diff-685da2f87189fff825b7aec2666cfbabdb33c40f8f9d8c82df77ebb8652ccd4aR171)
*
[`core-web/libs/edit-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.spec.ts`](diffhunk://#diff-23d2e2fd9b71e1819e10ae720cb79ecf5e4d75e51fee641b020017fe8186640fR195-R197):
Added `LINE_DIVIDER` to the `FIELD_TYPES_COMPONENTS` and excluded it
from fields to be rendered.
[[1]](diffhunk://#diff-23d2e2fd9b71e1819e10ae720cb79ecf5e4d75e51fee641b020017fe8186640fR195-R197)
[[2]](diffhunk://#diff-23d2e2fd9b71e1819e10ae720cb79ecf5e4d75e51fee641b020017fe8186640fL209-R215)
*
[`core-web/libs/edit-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.ts`](diffhunk://#diff-f03434ad88316542a23c3fb0bf50b6650130632c3e7953d7ee3c882cb5950d06R1-R6):
Imported `NgTemplateOutlet` and `DividerModule` to support the new field
type.
[[1]](diffhunk://#diff-f03434ad88316542a23c3fb0bf50b6650130632c3e7953d7ee3c882cb5950d06R1-R6)
[[2]](diffhunk://#diff-f03434ad88316542a23c3fb0bf50b6650130632c3e7953d7ee3c882cb5950d06L61-R66)
*
[`core-web/libs/edit-content/src/lib/components/dot-edit-content-form/utils.ts`](diffhunk://#diff-48cac5197bbc560a4fdfa7a0c9bfab65eaab91bc8e90313f0b0644bdac7ec8b7L66-R67):
Added resolution function for `LINE_DIVIDER`.
*
[`core-web/libs/edit-content/src/lib/models/dot-edit-content-field.enum.ts`](diffhunk://#diff-aa72329fa1c18891b5d44042ac6ae09ff3d915621f16a084982f87d068c2453aL34-R35):
Added `LINE_DIVIDER` to the `FIELD_TYPES` enum.
*
[`core-web/libs/edit-content/src/lib/utils/mocks.ts`](diffhunk://#diff-044e3c643ab55d05bd081afffe7251b7ebec1f4c383851aa1a219cdc626093f1R740-R762):
Added mock data for `LINE_DIVIDER`.
[[1]](diffhunk://#diff-044e3c643ab55d05bd081afffe7251b7ebec1f4c383851aa1a219cdc626093f1R740-R762)
[[2]](diffhunk://#diff-044e3c643ab55d05bd081afffe7251b7ebec1f4c383851aa1a219cdc626093f1L769-R793)

### TypeScript Configuration Update:

*
[`core-web/tsconfig.base.json`](diffhunk://#diff-a96484261b73ba1eb1e119e1aa36e6be97f219d53cdbdbf3fc718cf11bfa98ebL15-R96):
Reformatted the `paths` section for better readability and consistency.
[[1]](diffhunk://#diff-a96484261b73ba1eb1e119e1aa36e6be97f219d53cdbdbf3fc718cf11bfa98ebL15-R96)
[[2]](diffhunk://#diff-a96484261b73ba1eb1e119e1aa36e6be97f219d53cdbdbf3fc718cf11bfa98ebL58-R153)

### Checklist
- [x] Tests
- [x] Translations
- [x] Security Implications Contemplated (add notes if applicable)

### Screenshots
Original             |  Updated
:-------------------------:|:-------------------------:
![MacBook
Pro-1736191191675](https://github.com/user-attachments/assets/ea22efac-5386-4fc6-9bf2-89657e1659a8)
| ![MacBook
Pro-1736191805768](https://github.com/user-attachments/assets/6de86c86-8f31-4e27-8e25-7985ef6c2fa2)

---------

Co-authored-by: Arcadio Quintero <[email protected]>
@github-project-automation github-project-automation bot moved this from In Review to Done in dotCMS - Product Planning Jan 7, 2025
@nicobytes nicobytes moved this from Done to Internal QA in dotCMS - Product Planning Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Internal QA
Development

Successfully merging a pull request may close this issue.

1 participant