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

!!! FEATURE: NodeTypeManager remove NodeType fallback handling #4466

Merged
merged 31 commits into from
Sep 29, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
d1eb6ab
Replace Node::nodeType access where possible and introduce fallback h…
Sep 1, 2023
85d87df
Consistently use NodeTypeNameFactory
Sep 1, 2023
4bde5aa
Remove fallback handling from NodeTypeManager
Sep 1, 2023
a864ced
Pacify linter
Sep 1, 2023
9d3efb3
Move ContentRepositoryRegistry injection to NodeTypeWithFallbackProvider
Sep 1, 2023
1881122
Merge branch '9.0' into nodeTypeFallbackHandling
Sep 1, 2023
e25a334
Provide content NodeTypeName in NodeTypeNameFactory
Sep 1, 2023
87ceb38
Adjust NodeType mocking
Sep 1, 2023
852a2dc
Avoid node mocking in NodeHelperTest
Sep 1, 2023
c8373fd
Make NodeHelperTest a proper functional test
Sep 1, 2023
364a230
Extract CR registry injection
Sep 8, 2023
9f66310
Ask the NodeTypeManager for existence of node types instead of catchi…
Sep 8, 2023
8de0062
Adjust NodeType documentation
Sep 8, 2023
059aa82
Ask NodeTypeManager for node type instead of catching exceptions
Sep 8, 2023
20480e9
Remove Fallback node configuration
Sep 8, 2023
c95d53d
Remove fallback node documentation
Sep 8, 2023
bbcf65a
Fix CR registry provider docs
Sep 8, 2023
faf4419
Merge remote-tracking branch 'origin/9.0' into nodeTypeFallbackHandling
mhsdesign Sep 24, 2023
bae8a3d
TASK: Remove `ContentRepositoryRegistryProvider` and use "classic" _p…
mhsdesign Sep 24, 2023
7f2dc54
TASK: `NodeTypeWithFallbackProvider` don't reimport `contentRepositor…
mhsdesign Sep 24, 2023
f8e875f
TASK: Deactivate `NodeHelperTest` for now
mhsdesign Sep 25, 2023
9078015
TASK: Remove hacky legacy `LoadNodeTypeTrait`
mhsdesign Sep 25, 2023
e20071e
TASK: Correctly inject `ContentRepositoryRegistry`
mhsdesign Sep 25, 2023
552a40a
Merge pull request #4559 from neos/nodeTypeFallbackHandling-review
mhsdesign Sep 25, 2023
a8b12ff
BUGFIX: Fix `Neos.Neos:FallbackNode` rendering
mhsdesign Sep 25, 2023
f1bceca
TASK: Adjust `NodeTypesCommandController` to changes in NodeTypeManager
mhsdesign Sep 26, 2023
844ad46
!!! TASK: Remove `NodeType::getName()` and replace usages
mhsdesign Sep 26, 2023
f02344c
Merge pull request #4562 from neos/task/removeNodeTypeGetName
mhsdesign Sep 28, 2023
4cdbd52
Merge remote-tracking branch 'origin/9.0' into nodeTypeFallbackHandling
mhsdesign Sep 29, 2023
98fa454
TASK: Adjust to removed `NodeType::getName`
mhsdesign Sep 29, 2023
2d3bc0a
TASK: Adjust fluid template to removed `NodeType::getName`
mhsdesign Sep 29, 2023
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
9 changes: 0 additions & 9 deletions Neos.ContentRepository.Core/Classes/NodeType/NodeType.php
Original file line number Diff line number Diff line change
Expand Up @@ -223,15 +223,6 @@ protected function applyPostprocessing(array $fullConfiguration): array
return $fullConfiguration;
}

/**
* Returns the name of this node type
* @deprecated use "name" property directly
*/
public function getName(): string
{
return $this->name->value;
}

/**
* Return boolean true if marked abstract
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ prototype(Neos.Neos:Content) < prototype(Neos.Fusion:Template) {
# attributes.class.@process.nodeType >
# }
# in your site's Fusion if you don't need that behavior.
attributes.class.@process.nodeType = ${Array.push(value, String.toLowerCase(String.pregReplace(node.nodeType.name, '/[[:^alnum:]]/', '-')))}
attributes.class.@process.nodeType = ${Array.push(value, String.toLowerCase(String.pregReplace(node.nodeTypeName.value, '/[[:^alnum:]]/', '-')))}

# The following line must not be removed as it adds required meta data to all content elements in backend
@process.contentElementWrapping {
Expand Down
2 changes: 1 addition & 1 deletion Neos.Neos/Resources/Private/Fusion/RawContent/Node.fusion
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
prototype(Neos.Neos:RawContent.Node) < prototype(Neos.Neos:ContentComponent) {

nodeType = ${node.nodeType.name}
nodeType = ${node.nodeTypeName.value}

renderer = Neos.Fusion:Case {
custom {
Expand Down
6 changes: 3 additions & 3 deletions Neos.Neos/Resources/Private/Fusion/RootCase.fusion
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ root {
documentType {
@position = 'end 9998'
condition = Neos.Fusion:CanRender {
type = ${documentNode.nodeType.name}
type = ${documentNode.nodeTypeName.value}
}
type = ${documentNode.nodeType.name}
type = ${documentNode.nodeTypeName.value}
}

default {
Expand All @@ -53,7 +53,7 @@ root {
error {
@position = 'end 10001'
condition = true
type = ${documentNode.nodeType.name}
type = ${documentNode.nodeTypeName.value}
}

@cache {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ prototype(Neos.NodeTypes.Navigation:Navigation) < prototype(Neos.Neos:Menu) {
maximumLevels = ${q(node).property('maximumLevels')}
maximumLevels.@process.1 = ${String.toInteger(value)}

attributes.class.@process.nodeType = ${Array.push(value, String.toLowerCase(String.pregReplace(node.nodeType.name, '/[[:^alnum:]]/', '-')))}
attributes.class.@process.nodeType = ${Array.push(value, String.toLowerCase(String.pregReplace(node.nodeTypeName.value, '/[[:^alnum:]]/', '-')))}

active.attributes = Neos.Fusion:Attributes {
class = 'active'
Expand Down