-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
…t such that you do not need to care about the id
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
after: anId with: aRenderable | ||
|
||
self turboStreamAction: 'after' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
append: anId with: aRenderable | ||
|
||
self turboStreamAction: 'append' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
before: anId with: aRenderable | ||
|
||
self turboStreamAction: 'before' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
prepend: anId with: aRenderable | ||
|
||
self turboStreamAction: 'prepend' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
remove: anId | ||
|
||
self turboStreamAction: 'remove' target: anId with: nil |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
convenience | ||
removeComponent: aComponent | ||
|
||
self remove: aComponent turboframeDecoration id |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
replace: anId with: aRenderable | ||
|
||
self turboStreamAction: 'replace' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
actions | ||
update: anId with: aRenderable | ||
|
||
self turboStreamAction: 'update' target: anId with: aRenderable |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
processing | ||
processRendering: aResponse | ||
|
||
self requestContext request isTurboFrameRequest | ||
ifTrue: [ | ||
aResponse | ||
doNotCache; | ||
contentType: self application contentType. | ||
self renderTurboFrameResponseOn: aResponse stream ] | ||
ifFalse: [ super processRendering: aResponse ] | ||
Check warning on line 10 in repository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/processRendering..st Codecov / codecov/patchrepository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/processRendering..st#L1-L10
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
accessing | ||
renderContext: anObject | ||
|
||
renderContext := anObject | ||
Check warning on line 4 in repository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/renderContext..st Codecov / codecov/patchrepository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/renderContext..st#L1-L4
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
rendering | ||
renderTurboFrameResponseOn: aStream | ||
"Render aRenderable on aStream." | ||
|
||
| document turboframeId | | ||
turboframeId := self requestContext request headerAt: 'turbo-frame'. | ||
document := (WAHtmlDocument on: aStream codec: self requestContext codec) | ||
scriptGenerator: self requestContext handler scriptGeneratorClass new; | ||
yourself. | ||
renderContext | ||
document: document | ||
during: [ | ||
renderContext | ||
visitor: ((WATurboFramePresenterGuide client: (WARenderVisitor context: renderContext)) id: turboframeId) | ||
during: [ | ||
self presenter renderWithContext: renderContext ] | ||
"self presenter allPresentersDo: [ :p | ((p isKindOf: WATurboFrame) and: [ turboframeId = p id ]) ifTrue:[ self halt. p renderWithContext: renderContext ] ]" ]. | ||
document scriptGenerator closeOn: document | ||
Check warning on line 18 in repository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/renderTurboFrameResponseOn..st Codecov / codecov/patchrepository/Seaside-RenderLoop.package/WATurboRenderPhaseContinuation.class/instance/renderTurboFrameResponseOn..st#L1-L18
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"commentStamp" : "", | ||
"super" : "WARenderPhaseContinuation", | ||
"category" : "Seaside-RenderLoop-Continuations", | ||
"classinstvars" : [ ], | ||
"pools" : [ ], | ||
"classvars" : [ ], | ||
"instvars" : [ | ||
"renderContext" | ||
], | ||
"name" : "WATurboRenderPhaseContinuation", | ||
"type" : "normal" | ||
} |