<div ng-controller="Umbraco.Editors.Media.CreateController">
	<div class="umb-dialog-body with-footer">
		<div class="umb-pane">

			<h5><localize key="create_createUnder">Create under</localize> {{currentNode.name}}</h5>

            <div ng-if="allowedTypes && allowedTypes.length === 0">
                <p class="abstract" ng-if="!hasSettingsAccess"><localize key="create_noMediaTypesWithNoSettingsAccess">The selected media in the tree doesn't allow for any other media to be created below it.</localize></p>
                <div ng-if="hasSettingsAccess">
                    <p class="abstract"><localize key="create_noMediaTypes">There are no allowed Media Types available for creating media here. You must enable these in <strong>Media Types
						Types</strong> within the <strong>Settings</strong> section, by editing the <strong>Allowed child node
						types</strong> under <strong>Permissions</strong>.</localize></p>
                    <a class="btn" href="#settings/mediaTypes/edit/{{mediaTypeId}}?view=permissions" role="button" ng-click="close()">
                        <localize key="create_noMediaTypesEditPermissions">Edit permissions for this Media Type</localize>
                    </a>
                </div>
            </div>

			<ul class="umb-actions umb-actions-child">
				<li data-element="action-{{docType.alias}}" class="umb-action" ng-repeat="docType in allowedTypes">
					<button type="button" ng-click="createMediaItem(docType)" class="umb-action-link umb-outline btn-reset">
						<umb-icon icon="{{docType.icon}}" class="icon large"></umb-icon>
						<span class="menu-label">
							{{docType.name}}
							<small>{{docType.description}}</small>
						</span>
					</button>
				</li>
			</ul>

		</div>
	</div>

	<div class="umb-dialog-footer btn-toolbar umb-btn-toolbar">
		<button type="button" class="btn btn-info" ng-click="closeDialog()">
			<localize key="buttons_somethingElse">Do something else</localize>
		</button>
	</div>

</div>
