Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta name="description" content="SVG Alphabets">
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>SVG Letters</title>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.0/angular.min.js"></script>
  
</head>
<body ng-app="myApp">
  
  <div ng-controller="alphabetsController">
    <div class="capital-letters-list" style="zoom:{{zoom}}">
      <ng-template ng-repeat="letter in capitalLetters">
        <svg viewBox="0 0 27 40">
          <path d="{{letter.value}}"/>
        </svg>
        <div ng-if="($index % 4)===3"></div>
      </ng-template>
    </div>
  
    <div class="floating-control">
      <input type="range" ng-model="zoom" max="1.0" min="0.2" step="0.005">
    </div>
  </div>
</body>
</html>
 
console.clear();
var CAPITAL_LETTERS = {
  "a": [
    "M24,36",
    "L24,20",
    "L13,3",
    "L3,20",
    "L3,36",
    "M3,20",
    "L24,20"
  ],
  "b": [
    "M20,20",
    "L20,3",
    "L3,3",
    "L3,36",
    "L24,36",
    "L24,20",
    "L3,20"
  ],
  "c": [
    "M24,3",
    "L3,3",
    "L3,20",
    "L3,36",
    "L24,36"
  ],
  "d": [
    "M3,3",
    "L24,3",
    "L24,36",
    "L3,36",
    "M6,3",
    "L6,36"
  ],
  "e": [
    "M24,3",
    "L3,3",
    "L3,36",
    "L24,36",
    "M3,20",
    "L20,20"
  ],
  "f": [
    "M24,3",
    "L3,3",
    "L3,36",
    "M3,20",
    "L20,20"
  ],
  "g": [
    "M24,3",
    "L3,3",
    "L3,20",
    "L3,36",
    "L24,36",
    "L24,20",
    "L14,20"
  ],
  "h": [
    "M3,3",
    "L3,36",
    "M3,20",
    "L24,20",
    "M24,3",
    "L24,36"
  ],
  "i": [
    "M3,3",
    "L24,3",
    "M3,36",
    "L24,36",
    "M13,3",
    "L13,36"
  ],
  "j": [
    "M3,3",
    "L24,3",
    "M20,3",
    "L20,36",
    "L3,36",
    "L3,25"
  ],
  "k": [
    "M3,3",
    "L3,36",
    "M18,3",
    "L3,20",
    "L18,36"
  ],
  "l": [
    "M3,3",
    "L3,36",
    "L24,36"
  ],
  "m": [
    "M3,36",
    "L3,3",
    "L14,20",
    "L24,3",
    "L24,36"
  ],
  "n": [
    "M3,36",
    "L3,3",
    "L24,36",
    "L24,3"
  ],
  "o": [
    "M3,3",
    "L3,36",
    "L24,36",
    "L24,3",
    "L3,3"
  ],
  "p": [
    "M3,20",
    "L20,20",
    "L20,3",
    "L3,3",
    "L3,36"
  ],
  "q": [
    "M3,3",
    "L3,36",
    "L24,36",
    "L24,3",
    "L3,3",
    "M16,25",
    "L25,38"
  ],
  "r": [
    "M3,20",
    "L20,20",
    "L20,3",
    "L3,3",
    "L3,36",
    "M16,20",
    "L22,36"
  ],
  "s": [
    "M24,3",
    "L3,3",
    "L3,20",
    "L24,20",
    "L24,36",
    "L3,36"
  ],
  "t": [
    "M3,3",
    "L24,3",
    "M14,3",
    "L14,36"
  ],
  "u": [
    "M3,3",
    "L3,36",
    "L24,36",
    "L24,3"
  ],
  "v": [
    "M3,3",
    "L14,36",
    "L24,3"
  ],
  "w": [
    "M3,3",
    "L5,36",
    "L14,10",
    "L22,36",
    "L24,3"
  ],
  "x": [
    "M3,3",
    "L24,36",
    "M3,36",
    "L24,3"
// A
  ],
  "y": [
    "M3,3",
    "L14,20",
    "L24,3",
    "M14,20",
    "L14,36"
  ],
  "z": [
    "M3,3",
    "L24,3",
    "L3,36",
    "L24,36"
  ]
};
function obToList(ob){
  return Object.keys(ob).map(key=>{
    return {
      key:key,
      value: ob[key].join('')
    };
  });
}
var myApp = angular.module('myApp', []);
myApp.controller('alphabetsController',['$scope', function($scope){
  
  $scope.capitalLetters = obToList(CAPITAL_LETTERS);
  $scope.zoom = 0.5;
  
}]);
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
sam016pro
0viewers