Commit 81f69797 authored by Ilya Shulgin's avatar Ilya Shulgin

Изменения css

parent e775af9a
class CreateController {
constructor($scope, $location) {
$scope.isRouteActive = function(route) {
let curRoute = $location.path();
return curRoute.match(route);
}
constructor($scope, $location, $http) {
$scope.contents = [
{name: "link2", value: "Дополнительное поле для ссылки"},
{name: "link3", value: "Дополнительное поле для ссылки"},
{name: "link4", value: "Дополнительное поле для ссылки"},
{name: "link5", value: "Дополнительное поле для ссылки"}];
}
}
CreateController.$inject = ['$scope', '$location'];
CreateController.$inject = ['$scope', '$location', '$http'];
export default CreateController;
\ No newline at end of file
<div class="col-md-12">
<header class="header">
<img class="header__image" src="/static/images/true_logo.png" alt="ЛЕНТАЧ">
<img class="header__image" src="/static/images/true_logo.png" alt="ЛЕНТАЧ">
</header>
<form class="user form">
<form>
<div class="input-group">
<label for="description">
......@@ -13,12 +13,22 @@
</div>
<div class="input-group">
<label for="source">
<label for="link1">
Ссылки:
</label>
<input type="text" id="source" class="form-control" placeholder="Ссылки на источники, издания или ресурсы">
<input type="text" id="link1" class="form-control" placeholder="Краткое описание вашей новости">
<div ng-repeat="content in contents">
<input type="text" class="form-control" name="{{content.name}}" placeholder="{{content.value}}"/>
</div>
</div>
<!--<div class="input-group">-->
<!--<label for="source">-->
<!--Ссылки:-->
<!--</label>-->
<!--<input type="text" id="source" class="form-control" placeholder="Ссылки на источники, издания или ресурсы">-->
<!--</div>-->
<div class="input-group">
<label for="text">
Текст новости:
......@@ -31,7 +41,7 @@
var observe;
if (window.attachEvent) {
observe = function (element, event, handler) {
element.attachEvent('on'+event, handler);
element.attachEvent('on' + event, handler);
};
}
else {
......@@ -39,20 +49,24 @@
element.addEventListener(event, handler, false);
};
}
function init () {
function init() {
var text = document.getElementById('text');
function resize () {
function resize() {
text.style.height = 'auto';
text.style.height = text.scrollHeight+'px';
text.style.height = text.scrollHeight + 'px';
}
/* 0-timeout to get the already changed text */
function delayedResize () {
function delayedResize() {
window.setTimeout(resize, 0);
}
observe(text, 'change', resize);
observe(text, 'cut', delayedResize);
observe(text, 'paste', delayedResize);
observe(text, 'drop', delayedResize);
observe(text, 'change', resize);
observe(text, 'cut', delayedResize);
observe(text, 'paste', delayedResize);
observe(text, 'drop', delayedResize);
observe(text, 'keydown', delayedResize);
text.focus();
......
......@@ -66,11 +66,6 @@ label {
margin: 0 !important;
}
.listview__sidebar .list-group-item {
border-top-right-radius: 0 !important;
border-top-left-radius: 0 !important;
}
.listview__content {
padding: 0 !important;
margin: 0 !important;
......@@ -78,4 +73,8 @@ label {
.menu-space-bottom{
margin-bottom: 20px !important;
}
.input-group .form-control {
border-radius: 4px !important;
}
\ No newline at end of file
......@@ -26,6 +26,5 @@ angular.module('echoes')
});
}])
.controller('SubmitController', SubmitController)
.controller('CreateController', CreateController)
.controller('HistoryController', HistoryController);
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment