﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl">
	<xsl:output method="xml" indent="yes"/>

	<xsl:template match="/">
		<div class="container">
			<xsl:apply-templates select ="//Layout/Division"></xsl:apply-templates>
		</div>
	</xsl:template>

	<xsl:template match="Division">
		<div class="row">
			<xsl:apply-templates select ="Block"></xsl:apply-templates>
		</div>
	</xsl:template>

	<xsl:template match="Block">
		<xsl:choose>
			<xsl:when test="Type='OneFourth'">
				<div class="col-md-3 col-sm-6">
					<div class="icon-stat" style="height:128px;">
					</div>
				</div>
			</xsl:when>
			<xsl:when test="Type='OneThird'">
				<div class="col-md-4 col-sm-4">
					<div class="portlet portlet-boxed" style="height:463px;border-radius: 4px; border: 1px solid #ddd;background-color: #fff;">
					</div>
				</div>
			</xsl:when>
			<xsl:when test="Type='TwoThird'">
				<div class="col-md-8 col-sm-8">
					<div class="portlet portlet-boxed" style="height:463px;border-radius: 4px; border: 1px solid #ddd;background-color: #fff;">
					</div>
				</div>
			</xsl:when>
			<xsl:when test="Type='Half'">
				<div class="col-md-6 col-sm-6">
					<div class="portlet portlet-boxed" style="height:463px;border-radius: 4px; border: 1px solid #ddd;background-color: #fff;">
					</div>
				</div>
			</xsl:when>
			<xsl:when test="Type='Full'">
				<div class="col-md-12 col-sm-12">
					<div class="portlet portlet-boxed" style="height:463px;border-radius: 4px; border: 1px solid #ddd;background-color: #fff;">
					</div>
				</div>
			</xsl:when>
		</xsl:choose>
	</xsl:template>
</xsl:stylesheet>
