This file contains hidden or 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
| // var parser = new FluidParser(); | |
| // parser.ParseFromFile("deane"); | |
| namespace DeaneBarker.Fluid | |
| { | |
| public static class FluidParserExtensions | |
| { | |
| public static IFluidTemplate ParseFromFile(this FluidParser parser, string path) | |
| { | |
| if(TemplateOptions.Default.FileProvider == null) |
This file contains hidden or 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
| This file exists just to name the gist... |
This file contains hidden or 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 Scriban; | |
| using Scriban.Parsing; | |
| using Scriban.Runtime; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.IO; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| using Wyam.Common.Configuration; |
This file contains hidden or 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
| public class XmlNode : Drop | |
| { | |
| private const string attributeMethodName = "attr"; | |
| private const string xpathQueryMethodName = "xpath"; | |
| private const string listQueryMethodName = "list"; | |
| private const char shorthandDelimiter = '-'; | |
| private XmlElement doc; | |
| public XmlNode(XmlDocument xml) |
This file contains hidden or 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
| // If you think it's brilliant, then this is completely intentional. | |
| // If you think it's dumb, then this is intended ironically because I'm just _that_ smart. | |
| StringMatcher.IsMatch("Deane Barker", "deane ", StringMatchMethod.Starts, StringMatchOptions.IgnoreCase | StringMatchOptions.Trim); // True | |
| StringMatcher.IsMatch("Deane Barker", "Barker", StringMatchMethod.Ends); // True | |
| StringMatcher.IsMatch("Deane Barker", "ARK", StringMatchMethod.Contains, StringMatchOptions.IgnoreCase); // True | |
| // etc. | |
| // In reality, this is intended for use with a particular CMS, so that the editing interface can be dynamically generated | |
| // based on the code. A dropdown will generate for the values in StringMatchMethod, and checkboxes will generate for the |
This file contains hidden or 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( | |
| ["dojo/_base/declare", "dojo/ready", "dijit/_Widget", "dijit/_TemplatedMixin", "epi/epi"], | |
| function (declare, ready, _Widget, _TemplatedMixin, epi) { | |
| return declare( | |
| [_Widget, _TemplatedMixin], | |
| { | |
| templateString: '<textarea data-dojo-attach-event="onchange:_onChange"></textarea>', | |
| constructor: function () { | |
| ready(this, function () { |
This file contains hidden or 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 EPiServer.Enterprise; | |
| using EPiServer.Enterprise.Mirroring; | |
| using EPiServer.Framework; | |
| using EPiServer.Framework.Initialization; | |
| using EPiServer.MirroringService; | |
| using EPiServer.MirroringService.Common; | |
| using EPiServer.MirroringService.MirroringMonitoring; | |
| using EPiServer.MirroringService.MirroringTransferProtocol.Common; | |
| using System; | |
| using System.Linq; |
This file contains hidden or 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
| <!-- | |
| This is a textarea that: | |
| (1) Is styled(-ish) like a code editor | |
| (2) Catches tabs and converts them to four (4) spaces | |
| (3) Duplicates leading spaces from the last line | |
| (4) Auto-expands to input | |
| Pure inline HTML and JavaScript. No external dependencies. Has issues pre-IE-8, but should be otherwise okay. |
This file contains hidden or 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 EPiServer.Core; | |
| using EPiServer.Framework; | |
| using EPiServer.Framework.Initialization; | |
| using EPiServer.ServiceLocation; | |
| using EPiServer.Web; | |
| using System.Linq; | |
| using System.Web; | |
| namespace BlendInteractive.Business | |
| { |
This file contains hidden or 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
| <html> | |
| <head> | |
| <link href="https://contentful.github.io/ui-extensions-sdk/cf-extension.css" rel="stylesheet"> | |
| <script src="https://contentful.github.io/ui-extensions-sdk/cf-extension-api.js"></script> | |
| <script src="https://cdnjs.cloudflare.com/ajax/libs/mustache.js/2.2.1/mustache.min.js"></script> | |
| <style> | |
| body { | |
| margin: 0; | |
| color: #8091a5 !important; | |
| overflow: hidden; |