Browse Source

Simplified the SubdomainRoute to allow a single route to specify multiple subdomains.

Changed method of routing so that on dev, you use the sub param instead of an additional directory.
master
Teknikode 7 years ago
parent
commit
5fb06265b3
  1. 39
      Teknik/App_Start/SubdomainRoute.cs
  2. 68
      Teknik/App_Start/SubdomainRouteExtension.cs
  3. 34
      Teknik/Areas/API/APIAreaRegistration.cs
  4. 12
      Teknik/Areas/About/AboutAreaRegistration.cs
  5. 30
      Teknik/Areas/Blog/BlogAreaRegistration.cs
  6. 21
      Teknik/Areas/Contact/ContactAreaRegistration.cs
  7. 3
      Teknik/Areas/Dev/Controllers/DevController.cs
  8. 7
      Teknik/Areas/Dev/DevAreaRegistration.cs
  9. 5
      Teknik/Areas/Error/ErrorAreaRegistration.cs
  10. 75
      Teknik/Areas/Help/HelpAreaRegistration.cs
  11. 4
      Teknik/Areas/Help/Views/Help/API/v1/Upload.cshtml
  12. 26
      Teknik/Areas/Home/HomeAreaRegistration.cs
  13. 18
      Teknik/Areas/Paste/Controllers/PasteController.cs
  14. 13
      Teknik/Areas/Paste/Models/Paste.cs
  15. 56
      Teknik/Areas/Paste/PasteAreaRegistration.cs
  16. 13
      Teknik/Areas/Paste/ViewModels/PasteViewModel.cs
  17. 4
      Teknik/Areas/Paste/Views/Paste/Index.cshtml
  18. 3
      Teknik/Areas/Paste/Views/_ViewStart.cshtml
  19. 36
      Teknik/Areas/Paste/Views/web.config
  20. 12
      Teknik/Areas/Privacy/PrivacyAreaRegistration.cs
  21. 48
      Teknik/Areas/Profile/ProfileAreaRegistration.cs
  22. 67
      Teknik/Areas/Upload/UploadAreaRegistration.cs
  23. 108
      Teknik/Content/Highlight/agate.css
  24. 66
      Teknik/Content/Highlight/androidstudio.css
  25. 88
      Teknik/Content/Highlight/arduino-light.css
  26. 73
      Teknik/Content/Highlight/arta.css
  27. 45
      Teknik/Content/Highlight/ascetic.css
  28. 83
      Teknik/Content/Highlight/atelier-cave-dark.css
  29. 85
      Teknik/Content/Highlight/atelier-cave-light.css
  30. 69
      Teknik/Content/Highlight/atelier-dune-dark.css
  31. 69
      Teknik/Content/Highlight/atelier-dune-light.css
  32. 84
      Teknik/Content/Highlight/atelier-estuary-dark.css
  33. 84
      Teknik/Content/Highlight/atelier-estuary-light.css
  34. 69
      Teknik/Content/Highlight/atelier-forest-dark.css
  35. 69
      Teknik/Content/Highlight/atelier-forest-light.css
  36. 69
      Teknik/Content/Highlight/atelier-heath-dark.css
  37. 69
      Teknik/Content/Highlight/atelier-heath-light.css
  38. 69
      Teknik/Content/Highlight/atelier-lakeside-dark.css
  39. 69
      Teknik/Content/Highlight/atelier-lakeside-light.css
  40. 84
      Teknik/Content/Highlight/atelier-plateau-dark.css
  41. 84
      Teknik/Content/Highlight/atelier-plateau-light.css
  42. 84
      Teknik/Content/Highlight/atelier-savanna-dark.css
  43. 84
      Teknik/Content/Highlight/atelier-savanna-light.css
  44. 69
      Teknik/Content/Highlight/atelier-seaside-dark.css
  45. 69
      Teknik/Content/Highlight/atelier-seaside-light.css
  46. 69
      Teknik/Content/Highlight/atelier-sulphurpool-dark.css
  47. 69
      Teknik/Content/Highlight/atelier-sulphurpool-light.css
  48. 64
      Teknik/Content/Highlight/brown-paper.css
  49. BIN
      Teknik/Content/Highlight/brown-papersq.png
  50. 60
      Teknik/Content/Highlight/codepen-embed.css
  51. 71
      Teknik/Content/Highlight/color-brewer.css
  52. 63
      Teknik/Content/Highlight/dark.css
  53. 74
      Teknik/Content/Highlight/darkula.css
  54. 77
      Teknik/Content/Highlight/default.css
  55. 97
      Teknik/Content/Highlight/docco.css
  56. 71
      Teknik/Content/Highlight/far.css
  57. 88
      Teknik/Content/Highlight/foundation.css
  58. 71
      Teknik/Content/Highlight/github-gist.css
  59. 99
      Teknik/Content/Highlight/github.css
  60. 89
      Teknik/Content/Highlight/googlecode.css
  61. 101
      Teknik/Content/Highlight/grayscale.css
  62. 83
      Teknik/Content/Highlight/hopscotch.css
  63. 102
      Teknik/Content/Highlight/hybrid.css
  64. 97
      Teknik/Content/Highlight/idea.css
  65. 73
      Teknik/Content/Highlight/ir-black.css
  66. 74
      Teknik/Content/Highlight/kimbie.dark.css
  67. 74
      Teknik/Content/Highlight/kimbie.light.css
  68. 70
      Teknik/Content/Highlight/magula.css
  69. 59
      Teknik/Content/Highlight/mono-blue.css
  70. 83
      Teknik/Content/Highlight/monokai-sublime.css
  71. 70
      Teknik/Content/Highlight/monokai.css
  72. 88
      Teknik/Content/Highlight/obsidian.css
  73. 72
      Teknik/Content/Highlight/paraiso-dark.css
  74. 72
      Teknik/Content/Highlight/paraiso-light.css
  75. 83
      Teknik/Content/Highlight/pojoaque.css
  76. BIN
      Teknik/Content/Highlight/pojoaque.jpg
  77. 106
      Teknik/Content/Highlight/railscasts.css
  78. 85
      Teknik/Content/Highlight/rainbow.css
  79. 72
      Teknik/Content/Highlight/school-book.css
  80. BIN
      Teknik/Content/Highlight/school-book.png
  81. 84
      Teknik/Content/Highlight/solarized-dark.css
  82. 84
      Teknik/Content/Highlight/solarized-light.css
  83. 102
      Teknik/Content/Highlight/sunburst.css
  84. 75
      Teknik/Content/Highlight/tomorrow-night-blue.css
  85. 74
      Teknik/Content/Highlight/tomorrow-night-bright.css
  86. 74
      Teknik/Content/Highlight/tomorrow-night-eighties.css
  87. 75
      Teknik/Content/Highlight/tomorrow-night.css
  88. 72
      Teknik/Content/Highlight/tomorrow.css
  89. 68
      Teknik/Content/Highlight/vs.css
  90. 93
      Teknik/Content/Highlight/xcode.css
  91. 80
      Teknik/Content/Highlight/zenburn.css
  92. 19
      Teknik/Helpers/UrlExtensions.cs
  93. 4
      Teknik/Scripts/Highlight/highlight.pack.js
  94. BIN
      Teknik/Scripts/_references.js
  95. 79
      Teknik/Teknik.csproj

39
Teknik/App_Start/SubdomainRoute.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.IO;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Web;
using System.Web.Mvc;
@ -8,29 +9,29 @@ namespace Teknik @@ -8,29 +9,29 @@ namespace Teknik
{
public class SubdomainRoute : Route
{
public string Subdomain { get; set; }
public List<string> Subdomains { get; set; }
public SubdomainRoute(string subdomain, string url, IRouteHandler handler)
public SubdomainRoute(List<string> subdomains, string url, IRouteHandler handler)
: base(url, handler)
{
this.Subdomain = subdomain;
this.Subdomains = subdomains;
}
public SubdomainRoute(string subdomain, string url, RouteValueDictionary defaults, IRouteHandler handler)
public SubdomainRoute(List<string> subdomains, string url, RouteValueDictionary defaults, IRouteHandler handler)
: base(url, defaults, handler)
{
this.Subdomain = subdomain;
this.Subdomains = subdomains;
}
public SubdomainRoute(string subdomain, string url, RouteValueDictionary defaults, RouteValueDictionary constraints, IRouteHandler handler)
public SubdomainRoute(List<string> subdomains, string url, RouteValueDictionary defaults, RouteValueDictionary constraints, IRouteHandler handler)
: base(url, defaults, constraints, handler)
{
this.Subdomain = subdomain;
this.Subdomains = subdomains;
}
public SubdomainRoute(string subdomain, string url, RouteValueDictionary defaults, RouteValueDictionary constraints, RouteValueDictionary dataTokens, IRouteHandler handler)
public SubdomainRoute(List<string> subdomains, string url, RouteValueDictionary defaults, RouteValueDictionary constraints, RouteValueDictionary dataTokens, IRouteHandler handler)
: base(url, defaults, constraints, dataTokens, handler)
{
this.Subdomain = subdomain;
this.Subdomains = subdomains;
}
public override RouteData GetRouteData(HttpContextBase httpContext)
@ -38,10 +39,22 @@ namespace Teknik @@ -38,10 +39,22 @@ namespace Teknik
var routeData = base.GetRouteData(httpContext);
if (routeData == null) return null; // Only look at the subdomain if this route matches in the first place.
string subdomain = httpContext.Request.QueryString["sub"]; // A subdomain specified as a query parameter takes precedence over the hostname.
string host = httpContext.Request.Headers["Host"];
string curSub = host.GetSubdomain();
// special consideration for 'dev' subdomain
if (subdomain == null || subdomain == "dev")
{
if (!string.IsNullOrEmpty(curSub) && curSub == "dev")
{
// if we are on dev, and the param is dev or empty, we need to initialize it to 'www'
subdomain = "www";
}
}
if (subdomain == null)
{
string host = httpContext.Request.Headers["Host"];
subdomain = host.GetSubdomain();
subdomain = curSub;
}
else
{
@ -56,7 +69,7 @@ namespace Teknik @@ -56,7 +69,7 @@ namespace Teknik
}
//routeData.Values["sub"] = subdomain;
if (Subdomain == "*" || Subdomain == subdomain)
if (Subdomains.Contains("*") || Subdomains.Contains(subdomain))
{
return routeData;
}

68
Teknik/App_Start/SubdomainRouteExtension.cs

@ -1,140 +1,130 @@ @@ -1,140 +1,130 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Routing;
namespace Teknik
{
public static class SubdomainRouteExtension
{
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, string subDomain, string url, object defaults)
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, List<string> subDomains, string url, object defaults)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new MvcRouteHandler());
routes.Add(AddSubToName(subDomain, name), route);
routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, string subDomain, string url, object defaults, object constraints)
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, List<string> subDomains, string url, object defaults, object constraints)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(constraints),
new MvcRouteHandler());
routes.Add(AddSubToName(subDomain, name), route);
routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, string subDomain, string area, string url, object defaults, string[] namespaces)
public static SubdomainRoute MapSubdomainRoute(this RouteCollection routes, string name, List<string> subDomains, string area, string url, object defaults, string[] namespaces)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(new { }),
new RouteValueDictionary(new { Area = area, Namespaces = namespaces }),
new MvcRouteHandler());
routes.Add(AddSubToName(subDomain, name), route);
routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, object defaults)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, object defaults)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(new {}),
new RouteValueDictionary(new {Area = context.AreaName}),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, object defaults, object constraints)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, object defaults, object constraints)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(constraints),
new RouteValueDictionary(new {Area = context.AreaName}),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, object defaults, string[] namespaces)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, object defaults, string[] namespaces)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(new {}),
new RouteValueDictionary(new { Area = context.AreaName, Namespaces = namespaces }),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, string area, object defaults)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, string area, object defaults)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(new { }),
new RouteValueDictionary(new { Area = area }),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, string area, object defaults, object constraints)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, string area, object defaults, object constraints)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(constraints),
new RouteValueDictionary(new { Area = area }),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, string subDomain, string url, string area, object defaults, string[] namespaces)
public static SubdomainRoute MapSubdomainRoute(this AreaRegistrationContext context, string name, List<string> subDomains, string url, string area, object defaults, string[] namespaces)
{
SubdomainRoute route = new SubdomainRoute(
subDomain,
subDomains,
url,
new RouteValueDictionary(defaults),
new RouteValueDictionary(new { }),
new RouteValueDictionary(new { Area = area, Namespaces = namespaces }),
new MvcRouteHandler());
context.Routes.Add(AddSubToName(subDomain, name), route);
context.Routes.Add(name, route);
return route;
}
private static string AddSubToName(string sub, string name)
{
string newName = name;
if (!string.IsNullOrEmpty(sub))
{
newName = sub + "." + name;
}
return newName;
}
}
}

34
Teknik/Areas/API/APIAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
namespace Teknik.Areas.API
{
@ -17,30 +18,16 @@ namespace Teknik.Areas.API @@ -17,30 +18,16 @@ namespace Teknik.Areas.API
#region API v1
// Base Routing
context.MapSubdomainRoute(
"APIv1.Index", // Route name
"dev",
"API/v1", // URL with parameters
new { controller = "APIv1", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.APIv1Controller).Namespace }
);
context.MapSubdomainRoute(
"APIv1.Index", // Route name
"api",
"API.v1.Index", // Route name
new List<string>() { "dev", "api" },
"v1", // URL with parameters
new { controller = "APIv1", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.APIv1Controller).Namespace }
);
// Uploads
context.MapSubdomainRoute(
"APIv1.Upload", // Route name
"dev",
"API/v1/Upload", // URL with parameters
new { controller = "APIv1", action = "Upload" }, // Parameter defaults
new[] { typeof(Controllers.APIv1Controller).Namespace }
);
context.MapSubdomainRoute(
"APIv1.Upload", // Route name
"api",
"API.v1.Upload", // Route name
new List<string>() { "dev", "api" },
"v1/Upload", // URL with parameters
new { controller = "APIv1", action = "Upload" }, // Parameter defaults
new[] { typeof(Controllers.APIv1Controller).Namespace }
@ -50,14 +37,7 @@ namespace Teknik.Areas.API @@ -50,14 +37,7 @@ namespace Teknik.Areas.API
// Default Routing
context.MapSubdomainRoute(
"API.Index", // Route name
"dev",
"API", // URL with parameters
new { controller = "API", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.APIController).Namespace }
);
context.MapSubdomainRoute(
"API.Index", // Route name
"api",
new List<string>() { "dev", "" },
"", // URL with parameters
new { controller = "API", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.APIController).Namespace }

12
Teknik/Areas/About/AboutAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
namespace Teknik.Areas.About
{
@ -16,14 +17,7 @@ namespace Teknik.Areas.About @@ -16,14 +17,7 @@ namespace Teknik.Areas.About
{
context.MapSubdomainRoute(
"About.Index", // Route name
"dev",
"About", // URL with parameters
new { controller = "About", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.AboutController).Namespace }
);
context.MapSubdomainRoute(
"About.Index", // Route name
"about",
new List<string>() { "dev", "about" },
"", // URL with parameters
new { controller = "About", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.AboutController).Namespace }

30
Teknik/Areas/Blog/BlogAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Blog
@ -17,42 +18,21 @@ namespace Teknik.Areas.Blog @@ -17,42 +18,21 @@ namespace Teknik.Areas.Blog
{
context.MapSubdomainRoute(
"Blog.Blog", // Route name
"dev",
"Blog/{username}", // URL with parameters
new { controller = "Blog", action = "Blog", username = string.Empty }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }
);
context.MapSubdomainRoute(
"Blog.Post", // Route name
"dev",
"Blog/{username}/{id}", // URL with parameters
new { controller = "Blog", action = "Post", username = "", id = 0 }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }
);
context.MapSubdomainRoute(
"Blog.Action", // Route name
"dev",
"Blog/Action/{controller}/{action}", // URL with parameters
new { controller = "Blog", action = "Blog" }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }
);
context.MapSubdomainRoute(
"Blog.Blog", // Route name
"blog",
new List<string>() { "dev", "blog" }, // Subdomains
"{username}", // URL with parameters
new { controller = "Blog", action = "Blog", username = string.Empty }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }
);
context.MapSubdomainRoute(
"Blog.Post", // Route name
"blog",
new List<string>() { "dev", "blog" }, // Subdomains
"{username}/{id}", // URL with parameters
new { controller = "Blog", action = "Post", username = "", id = 0 }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }
);
context.MapSubdomainRoute(
"Blog.Action", // Route name
"blog",
new List<string>() { "dev", "blog" }, // Subdomains
"Action/{controller}/{action}", // URL with parameters
new { controller = "Blog", action = "Blog" }, // Parameter defaults
new[] { typeof(Controllers.BlogController).Namespace }

21
Teknik/Areas/Contact/ContactAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Contact
@ -17,28 +18,14 @@ namespace Teknik.Areas.Contact @@ -17,28 +18,14 @@ namespace Teknik.Areas.Contact
{
context.MapSubdomainRoute(
"Contact.Index", // Route name
"dev",
"Contact/", // URL with parameters
new { controller = "Contact", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ContactController).Namespace }
);
context.MapSubdomainRoute(
"Contact.Action", // Route name
"dev",
"Contact/{action}", // URL with parameters
new { controller = "Contact", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ContactController).Namespace }
);
context.MapSubdomainRoute(
"Contact.Index", // Route name
"contact",
new List<string>() { "dev", "contact" }, // Subdomains
"", // URL with parameters
new { controller = "Contact", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ContactController).Namespace }
);
context.MapSubdomainRoute(
"Contact.Action", // Route name
"contact",
new List<string>() { "dev", "contact" }, // Subdomains
"{action}", // URL with parameters
new { controller = "Contact", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ContactController).Namespace }

3
Teknik/Areas/Dev/Controllers/DevController.cs

@ -13,8 +13,7 @@ namespace Teknik.Areas.Dev.Controllers @@ -13,8 +13,7 @@ namespace Teknik.Areas.Dev.Controllers
// GET: Dev
public ActionResult Index()
{
ViewBag.Title = Config.Title + " - Development";
return View("~/Areas/Dev/Views/Dev/Index.cshtml");
return Redirect(Url.SubRouteUrl("www", "Home.Index"));
}
}
}

7
Teknik/Areas/Dev/DevAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using Teknik.Areas.Home.Controllers;
namespace Teknik.Areas.Dev
@ -17,8 +18,8 @@ namespace Teknik.Areas.Dev @@ -17,8 +18,8 @@ namespace Teknik.Areas.Dev
{
context.MapSubdomainRoute(
"Dev.Index", // Route name
"dev",
"Dev/{controller}/{action}", // URL with parameters
new List<string>() { "dev" }, // Subdomains
"", // URL with parameters
new { controller = "Dev", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.DevController).Namespace }
);

5
Teknik/Areas/Error/ErrorAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
namespace Teknik.Areas.Error
{
@ -16,7 +17,7 @@ namespace Teknik.Areas.Error @@ -16,7 +17,7 @@ namespace Teknik.Areas.Error
{
context.MapSubdomainRoute(
"Error.Http404", // Route name
"*",
new List<string>() { "*" }, // Subdomains
"Error/404", // URL with parameters
new { controller = "Error", action = "Http404" }, // Parameter defaults
new[] { typeof(Controllers.ErrorController).Namespace }

75
Teknik/Areas/Help/HelpAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Help
@ -17,112 +18,56 @@ namespace Teknik.Areas.Help @@ -17,112 +18,56 @@ namespace Teknik.Areas.Help
{
context.MapSubdomainRoute(
"Help.Index", // Route name
"dev",
"Help", // URL with parameters
new { controller = "Help", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.API", // Route name
"dev",
"Help/API/{version}/{service}", // URL with parameters
new { controller = "Help", action = "API", version = UrlParameter.Optional, service = UrlParameter.Optional }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Blog", // Route name
"dev",
"Help/Blog", // URL with parameters
new { controller = "Help", action = "Blog" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Git", // Route name
"dev",
"Help/Git", // URL with parameters
new { controller = "Help", action = "Git" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.IRC", // Route name
"dev",
"Help/IRC", // URL with parameters
new { controller = "Help", action = "IRC" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Mail", // Route name
"dev",
"Help/Mail", // URL with parameters
new { controller = "Help", action = "Mail" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Mumble", // Route name
"dev",
"Help/Mumble", // URL with parameters
new { controller = "Help", action = "Mumble" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Upload", // Route name
"dev",
"Help/Upload", // URL with parameters
new { controller = "Help", action = "Upload" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Index", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"", // URL with parameters
new { controller = "Help", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.API", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"API/{version}/{service}", // URL with parameters
new { controller = "Help", action = "API", version = UrlParameter.Optional, service = UrlParameter.Optional }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Blog", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"Blog", // URL with parameters
new { controller = "Help", action = "Blog" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Git", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"Git", // URL with parameters
new { controller = "Help", action = "Git" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.IRC", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"IRC", // URL with parameters
new { controller = "Help", action = "IRC" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Mail", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"Mail", // URL with parameters
new { controller = "Help", action = "Mail" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Mumble", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"Mumble", // URL with parameters
new { controller = "Help", action = "Mumble" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }
);
context.MapSubdomainRoute(
"Help.Upload", // Route name
"help",
new List<string>() { "dev", "help" }, // Subdomains
"Upload", // URL with parameters
new { controller = "Help", action = "Upload" }, // Parameter defaults
new[] { typeof(Controllers.HelpController).Namespace }

4
Teknik/Areas/Help/Views/Help/API/v1/Upload.cshtml

@ -8,7 +8,7 @@ @@ -8,7 +8,7 @@
<hr>
<p>This is a description of the API commands available for the Upload service.</p>
<h3>Upload a File</h3>
<pre><code>POST @Url.SubRouteUrl("api", "APIv1.Upload")</code></pre>
<pre><code>POST @Url.SubRouteUrl("api", "API.v1.Upload")</code></pre>
<h4>Parameters</h4>
<table>
<thead>
@ -265,7 +265,7 @@ @@ -265,7 +265,7 @@
</tbody>
</table>
<h4>Example</h4>
<pre><code>$ curl -F "genDeletionKey=true" -F "encrypt=true" -F "file=@("@")image.png" @Url.SubRouteUrl("api", "APIv1.Upload")</code></pre>
<pre><code>$ curl -F "genDeletionKey=true" -F "encrypt=true" -F "file=@("@")image.png" @Url.SubRouteUrl("api", "API.v1.Upload")</code></pre>
<p>
This will upload the file <var>image.png</var>, encrypt it, and then generate a deletion key.
</p>

26
Teknik/Areas/Home/HomeAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
using Teknik;
@ -18,28 +19,7 @@ namespace Teknik.Areas.Home @@ -18,28 +19,7 @@ namespace Teknik.Areas.Home
{
context.MapSubdomainRoute(
"Home.Index", // Route name
"dev",
"Home", // URL with parameters
new { controller = "Home", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HomeController).Namespace }
);
context.MapSubdomainRoute(
"Home.Default", // Route name
"dev",
"", // URL with parameters
new { controller = "Home", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HomeController).Namespace }
);
context.MapSubdomainRoute(
"Home.Index", // Route name
"www",
"", // URL with parameters
new { controller = "Home", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HomeController).Namespace }
);
context.MapSubdomainRoute(
"Home.Index", // Route name
string.Empty,
new List<string>() { "dev", "www", string.Empty }, // Subdomains
"", // URL with parameters
new { controller = "Home", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.HomeController).Namespace }

18
Teknik/Areas/Paste/Controllers/PasteController.cs

@ -0,0 +1,18 @@ @@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Teknik.Controllers;
namespace Teknik.Areas.Paste.Controllers
{
public class PasteController : DefaultController
{
// GET: Paste/Paste
public ActionResult Index()
{
return View();
}
}
}

13
Teknik/Areas/Paste/Models/Paste.cs

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Teknik.Areas.Paste.Models
{
public class Paste
{
}
}

56
Teknik/Areas/Paste/PasteAreaRegistration.cs

@ -0,0 +1,56 @@ @@ -0,0 +1,56 @@
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Paste
{
public class PasteAreaRegistration : AreaRegistration
{
public override string AreaName
{
get
{
return "Paste";
}
}
public override void RegisterArea(AreaRegistrationContext context)
{
context.MapSubdomainRoute(
"Paste.Index", // Route name
new List<string>() { "dev", "paste", "p" },
"", // URL with parameters
new { controller = "Paste", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.PasteController).Namespace }
);
context.MapSubdomainRoute(
"Paste.View", // Route name
new List<string>() { "dev", "paste", "p" },
"{id}", // URL with parameters
new { controller = "Paste", action = "View" }, // Parameter defaults
new[] { typeof(Controllers.PasteController).Namespace }
);
context.MapSubdomainRoute(
"Paste.Simple", // Route name
new List<string>() { "dev", "paste", "p" },
"Simple/{id}", // URL with parameters
new { controller = "Paste", action = "Simple" }, // Parameter defaults
new[] { typeof(Controllers.PasteController).Namespace }
);
context.MapSubdomainRoute(
"Paste.Raw", // Route name
new List<string>() { "dev", "paste", "p" },
"Raw/{id}", // URL with parameters
new { controller = "Paste", action = "Raw" }, // Parameter defaults
new[] { typeof(Controllers.PasteController).Namespace }
);
// Register Script Bundles
BundleTable.Bundles.Add(new ScriptBundle("~/bundles/paste").Include(
"~/Scripts/Highlight/highlight.pack.js"));
// Register Style Bundles
BundleTable.Bundles.Add(new StyleBundle("~/Content/paste").Include(
"~/Content/Highlight/default.css"));
}
}
}

13
Teknik/Areas/Paste/ViewModels/PasteViewModel.cs

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Teknik.ViewModels;
namespace Teknik.Areas.Paste.ViewModels
{
public class PasteViewModel : ViewModelBase
{
}
}

4
Teknik/Areas/Paste/Views/Paste/Index.cshtml

@ -0,0 +1,4 @@ @@ -0,0 +1,4 @@
@model Teknik.Areas.Paste.ViewModels.PasteViewModel
@Styles.Render("~/Content/paste");
@Scripts.Render("~/bundles/paste");

3
Teknik/Areas/Paste/Views/_ViewStart.cshtml

@ -0,0 +1,3 @@ @@ -0,0 +1,3 @@
@{
Layout = "~/Views/Shared/_Layout.cshtml";
}

36
Teknik/Areas/Paste/Views/web.config

@ -0,0 +1,36 @@ @@ -0,0 +1,36 @@
<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="system.web.webPages.razor" type="System.Web.WebPages.Razor.Configuration.RazorWebSectionGroup, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="host" type="System.Web.WebPages.Razor.Configuration.HostSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
<section name="pages" type="System.Web.WebPages.Razor.Configuration.RazorPagesSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
</sectionGroup>
</configSections>
<system.web.webPages.razor>
<host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<pages pageBaseType="System.Web.Mvc.WebViewPage">
<namespaces>
<add namespace="System.Web.Mvc" />
<add namespace="System.Web.Mvc.Ajax" />
<add namespace="System.Web.Mvc.Html" />
<add namespace="System.Web.Routing" />
<add namespace="System.Web.Optimization" />
<add namespace="Teknik" />
</namespaces>
</pages>
</system.web.webPages.razor>
<appSettings>
<add key="webpages:Enabled" value="false" />
</appSettings>
<system.webServer>
<handlers>
<remove name="BlockViewHandler"/>
<add name="BlockViewHandler" path="*" verb="*" preCondition="integratedMode" type="System.Web.HttpNotFoundHandler" />
</handlers>
</system.webServer>
</configuration>

12
Teknik/Areas/Privacy/PrivacyAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
namespace Teknik.Areas.Privacy
{
@ -16,14 +17,7 @@ namespace Teknik.Areas.Privacy @@ -16,14 +17,7 @@ namespace Teknik.Areas.Privacy
{
context.MapSubdomainRoute(
"Privacy.Index", // Route name
"dev",
"Privacy", // URL with parameters
new { controller = "Privacy", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.PrivacyController).Namespace }
);
context.MapSubdomainRoute(
"Privacy.Index", // Route name
"privacy",
new List<string>() { "dev", "privacy" }, // Subdomains
"", // URL with parameters
new { controller = "Privacy", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.PrivacyController).Namespace }

48
Teknik/Areas/Profile/ProfileAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Profile
@ -17,70 +18,35 @@ namespace Teknik.Areas.Profile @@ -17,70 +18,35 @@ namespace Teknik.Areas.Profile
{
context.MapSubdomainRoute(
"Profile.Login", // Route name
"dev",
"Profile/Login", // URL with parameters
new { controller = "Profile", action = "Login" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Logout", // Route name
"dev",
"Profile/Logout", // URL with parameters
new { controller = "Profile", action = "Logout" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Register", // Route name
"dev",
"Profile/Register", // URL with parameters
new { controller = "Profile", action = "Register" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Index", // Route name
"dev",
"Profile/{username}", // URL with parameters
new { controller = "Profile", action = "Index", username = UrlParameter.Optional }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Action", // Route name
"dev",
"Profile/Action/{action}", // URL with parameters
new { controller = "Profile", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Login", // Route name
"profile",
new List<string>() { "dev", "profile" }, // Subdomains
"Login", // URL with parameters
new { controller = "Profile", action = "Login" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Logout", // Route name
"profile",
new List<string>() { "dev", "profile" }, // Subdomains
"Logout", // URL with parameters
new { controller = "Profile", action = "Logout" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Register", // Route name
"profile",
new List<string>() { "dev", "profile" }, // Subdomains
"Register", // URL with parameters
new { controller = "Profile", action = "Register" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Index", // Route name
"profile",
new List<string>() { "dev", "profile" }, // Subdomains
"{username}", // URL with parameters
new { controller = "Profile", action = "Index", username = UrlParameter.Optional }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }
);
context.MapSubdomainRoute(
"Profile.Action", // Route name
"profile",
new List<string>() { "dev", "profile" }, // Subdomains
"Action/{action}", // URL with parameters
new { controller = "Profile", action = "Index" }, // Parameter defaults
new[] { typeof(Controllers.ProfileController).Namespace }

67
Teknik/Areas/Upload/UploadAreaRegistration.cs

@ -1,4 +1,5 @@ @@ -1,4 +1,5 @@
using System.Web.Mvc;
using System.Collections.Generic;
using System.Web.Mvc;
using System.Web.Optimization;
namespace Teknik.Areas.Upload
@ -17,84 +18,28 @@ namespace Teknik.Areas.Upload @@ -17,84 +18,28 @@ namespace Teknik.Areas.Upload
{
context.MapSubdomainRoute(
"Upload.Index",
"dev",
"Upload",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Download",
"dev",
"Upload/{file}",
new { controller = "Upload", action = "Download", file = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Delete",
"dev",
"Upload/{file}/{key}",
new { controller = "Upload", action = "Delete", file = string.Empty, key = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Action",
"dev",
"Upload/Action/{controller}/{action}",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Index",
"u",
"",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Download",
"u",
"{file}",
new { controller = "Upload", action = "Download", file = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Delete",
"u",
"{file}/{key}",
new { controller = "Upload", action = "Delete", file = string.Empty, key = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Action",
"u",
"Action/{controller}/{action}",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Index",
"upload",
new List<string>() { "dev", "upload", "u" }, // Subdomains
"",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Download",
"upload",
new List<string>() { "dev", "upload", "u" }, // Subdomains
"{file}",
new { controller = "Upload", action = "Download", file = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Delete",
"upload",
new List<string>() { "dev", "upload", "u" }, // Subdomains
"{file}/{key}",
new { controller = "Upload", action = "Delete", file = string.Empty, key = string.Empty },
new[] { typeof(Controllers.UploadController).Namespace }
);
context.MapSubdomainRoute(
"Upload.Action",
"upload",
new List<string>() { "dev", "upload", "u" }, // Subdomains
"Action/{controller}/{action}",
new { controller = "Upload", action = "Index" },
new[] { typeof(Controllers.UploadController).Namespace }

108
Teknik/Content/Highlight/agate.css

@ -0,0 +1,108 @@ @@ -0,0 +1,108 @@
/*!
* Agate by Taufik Nurrohman <https://github.com/tovic>
* ----------------------------------------------------
*
* #ade5fc
* #a2fca2
* #c6b4f0
* #d36363
* #fcc28c
* #fc9b9b
* #ffa
* #fff
* #333
* #62c8f3
* #888
*
*/
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
background: #333;
color: white;
}
.hljs-name,
.hljs-strong {
font-weight: bold;
}
.hljs-code,
.hljs-emphasis {
font-style: italic;
}
.hljs-tag {
color: #62c8f3;
}
.hljs-variable,
.hljs-template-variable,
.hljs-selector-id,
.hljs-selector-class {
color: #ade5fc;
}
.hljs-string,
.hljs-bullet {
color: #a2fca2;
}
.hljs-type,
.hljs-title,
.hljs-section,
.hljs-attribute,
.hljs-quote,
.hljs-built_in,
.hljs-builtin-name {
color: #ffa;
}
.hljs-number,
.hljs-symbol,
.hljs-bullet {
color: #d36363;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-literal {
color: #fcc28c;
}
.hljs-comment,
.hljs-deletion,
.hljs-code {
color: #888;
}
.hljs-regexp,
.hljs-link {
color: #c6b4f0;
}
.hljs-meta {
color: #fc9b9b;
}
.hljs-deletion {
background-color: #fc9b9b;
color: #333;
}
.hljs-addition {
background-color: #a2fca2;
color: #333;
}
.hljs a {
color: inherit;
}
.hljs a:focus,
.hljs a:hover {
color: inherit;
text-decoration: underline;
}

66
Teknik/Content/Highlight/androidstudio.css

@ -0,0 +1,66 @@ @@ -0,0 +1,66 @@
/*
Date: 24 Fev 2015
Author: Pedro Oliveira <kanytu@gmail . com>
*/
.hljs {
color: #a9b7c6;
background: #282b2e;
display: block;
overflow-x: auto;
padding: 0.5em;
}
.hljs-number,
.hljs-literal,
.hljs-symbol,
.hljs-bullet {
color: #6897BB;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-deletion {
color: #cc7832;
}
.hljs-variable,
.hljs-template-variable,
.hljs-link {
color: #629755;
}
.hljs-comment,
.hljs-quote {
color: #808080;
}
.hljs-meta {
color: #bbb529;
}
.hljs-string,
.hljs-attribute,
.hljs-addition {
color: #6A8759;
}
.hljs-section,
.hljs-title,
.hljs-type {
color: #ffc66d;
}
.hljs-name,
.hljs-selector-id,
.hljs-selector-class {
color: #e8bf6a;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}

88
Teknik/Content/Highlight/arduino-light.css

@ -0,0 +1,88 @@ @@ -0,0 +1,88 @@
/*
Arduino® Light Theme - Stefania Mellai <s.mellai@arduino.cc>
*/
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
background: #FFFFFF;
}
.hljs,
.hljs-subst {
color: #434f54;
}
.hljs-keyword,
.hljs-attribute,
.hljs-selector-tag,
.hljs-doctag,
.hljs-name {
color: #00979D;
}
.hljs-built_in,
.hljs-literal,
.hljs-bullet,
.hljs-code,
.hljs-addition {
color: #D35400;
}
.hljs-regexp,
.hljs-symbol,
.hljs-variable,
.hljs-template-variable,
.hljs-link,
.hljs-selector-attr,
.hljs-selector-pseudo {
color: #00979D;
}
.hljs-type,
.hljs-string,
.hljs-selector-id,
.hljs-selector-class,
.hljs-quote,
.hljs-template-tag,
.hljs-deletion {
color: #005C5F;
}
.hljs-title,
.hljs-section {
color: #880000;
font-weight: bold;
}
.hljs-comment {
color: rgba(149,165,166,.8);
}
.hljs-meta-keyword {
color: #728E00;
}
.hljs-meta {
color: #728E00;
color: #434f54;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
.hljs-function {
color: #728E00;
}
.hljs-number {
color: #8A7B52;
}

73
Teknik/Content/Highlight/arta.css

@ -0,0 +1,73 @@ @@ -0,0 +1,73 @@
/*
Date: 17.V.2011
Author: pumbur <pumbur@pumbur.net>
*/
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
background: #222;
}
.hljs,
.hljs-subst {
color: #aaa;
}
.hljs-section {
color: #fff;
}
.hljs-comment,
.hljs-quote,
.hljs-meta {
color: #444;
}
.hljs-string,
.hljs-symbol,
.hljs-bullet,
.hljs-regexp {
color: #ffcc33;
}
.hljs-number,
.hljs-addition {
color: #00cc66;
}
.hljs-built_in,
.hljs-builtin-name,
.hljs-literal,
.hljs-type,
.hljs-template-variable,
.hljs-attribute,
.hljs-link {
color: #32aaee;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-name,
.hljs-selector-id,