This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets | |
{ | |
public abstract class RenderAssetsProcessor | |
{ | |
public abstract void Process(RenderPageAssetsArgs args); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Web.UI; | |
using Sitecore.Pipelines; | |
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets | |
{ | |
[Serializable] | |
public class RenderPageAssetsArgs : PipelineArgs | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Sitecore.Web.UI; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Web.UI; | |
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets | |
{ | |
public class RenderAssetsControl : WebControl | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/"> | |
<sitecore> | |
<pageextenders> | |
<pageextender type="EditorEnhancementToolkit.Foundation.ContentEditor.PageExtenders.InjectAssetsPageExtender, EditorEnhancementToolkit.Foundation.ContentEditor" /> | |
</pageextenders> | |
<pipelines> | |
<renderPageAssets> | |
<processor type="EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets.GetStylesheets,EditorEnhancementToolkit.Foundation.ContentEditor"> | |
<sources hint="raw:AddSource"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets | |
{ | |
public class AssignPageAssetsToControl : RenderAssetsProcessor | |
{ | |
public override void Process(RenderPageAssetsArgs args) | |
{ | |
args.Control = new RenderAssetsControl | |
{ | |
StylesheetList = args.FilePaths | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Xml; | |
using Sitecore; | |
using Sitecore.Diagnostics; | |
using Sitecore.IO; | |
using Sitecore.Xml; | |
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<processor type="EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets.GetStylesheets,EditorEnhancementToolkit.Foundation.ContentEditor"> | |
<sources hint="raw:AddSource"> | |
<source folder="/sitecore modules/Shell/Editor Enhancement Toolkit/Assets/Stylesheets/" deep="false" pattern="*.css" /> | |
</sources> | |
</processor> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Web.UI; | |
using EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderPageAssets; | |
using Sitecore; | |
using Sitecore.Layouts; | |
using Sitecore.Layouts.PageExtenders; | |
using Sitecore.Pipelines; | |
namespace EditorEnhancementToolkit.Foundation.ContentEditor.PageExtenders | |
{ | |
public class InjectAssetsPageExtender : PageExtender |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define(["sitecore", "/-/speak/v1/ExperienceEditor/ExperienceEditor.js"], function (Sitecore, ExperienceEditor) { | |
return { | |
priority: 1, | |
execute: function () { | |
ExperienceEditor.Common.registerDocumentStyles(["/path to custom stylesheet/custom.css"], window.top.document); | |
} | |
}; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Sitecore; | |
using Sitecore.Mvc.ExperienceEditor.Presentation; | |
using Sitecore.Mvc.Pipelines.Response.RenderRendering; | |
using Sitecore.Mvc.Presentation; | |
namespace EditorEnhancementToolkit.Foundation.ContentEditor.Pipelines.RenderRenderer | |
{ | |
public class AddWrapper : Sitecore.Mvc.ExperienceEditor.Pipelines.Response.RenderRendering.AddWrapper | |
{ | |
public override void Process(RenderRenderingArgs args) |