Just a quick pen to illustrate a new property we can use to rotate a doughnut chart. This example is specific to the Chart.JS library.
A Pen by Mark Drake on CodePen.
@* | |
Block alias: `Example` | |
File path: Views/Partials/RichText/Components/Example.cshtml | |
*@ | |
@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage<Umbraco.Cms.Core.Models.Blocks.RichTextBlockItem> | |
@{ | |
var blockListItem = new BlockListItem(Model.ContentUdi, Model.Content, Model.SettingsUdi, Model.Settings); | |
} | |
<partial name="~/views/partials/blocklist/components/example.cshtml" model="blockListItem" /> |
var linksWithChildren = document.querySelectorAll("li.dynamic-children > a"); | |
for (var i = 0; i < linksWithChildren.length; i++){ | |
linksWithChildren[i].setAttribute("aria-haspopup","true") | |
} |
angular.module("umbraco").controller("Scylla.TextboxWithCharacterCount", function ($scope) | |
{ | |
// Loads Default Max Count | |
$scope.model.maxCount = $scope.model.config.maxCount; | |
// Attempts to re-define Max Count by description text | |
if ($scope.model.description) | |
{ | |
var maxSetInDescription = $scope.model.description.match(/\d+/); |
@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage | |
@using ContentModels = Umbraco.Cms.Web.Common.PublishedModels; | |
@{ | |
Layout = "template.cshtml"; | |
var currentPage = Umbraco.AssignedContentItem; | |
var root = currentPage.AncestorOrSelf(1); | |
} | |
<div class="sitemap"> |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using Microsoft.AspNetCore.Http; | |
using Umbraco.Cms.Core.Composing; | |
using Umbraco.Cms.Core.DependencyInjection; | |
using Umbraco.Forms.Core; | |
using Umbraco.Forms.Core.Enums; | |
using Umbraco.Forms.Core.Models; | |
using Umbraco.Forms.Core.Providers; |
.myUniqueClassName { | |
background: black; | |
color: white; | |
h1, h2, h3, h4, h5, h6, p, li, span, label { | |
font-size: 1rem; | |
} | |
} |
<!-- | |
Responsive Type through SVG | |
CodePen: https://codepen.io/markadrake/pen/dWgyvK | |
--> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>CodePen - SVG Text Spacing</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> |
// Concatenate Arrays using the Spread Operator in JavaScript | |
// CodePen: https://codepen.io/markadrake/pen/mMvYRQ | |
// Gist: https://gist.github.com/ | |
let myArray = [1], | |
mySecondArray = [2, 3], | |
myLastArray = [...myArray, ...mySecondArray]; // [1, 2, 3] |
Just a quick pen to illustrate a new property we can use to rotate a doughnut chart. This example is specific to the Chart.JS library.
A Pen by Mark Drake on CodePen.