1
一类我想通过我的自定义角指令在其标记的属性,有属性,该指令的模板的容器中的一个被指定为一类。链接的角度指令属性的模板与玉
这里是我的输入是什么样子,在玉:
.form-layout-group
short-text-input.item(label="Short Input Group", inputColumnsClass="short-text-2")
下面是返回我的指令功能:
function ShortTextInput (FormControlService) {
restrict: 'E',
replace: true,
require: ['^validationForm', '?ngModel', '^?formCollection'],
scope: {
inputColumnsClass: '@'
},
templateUrl: '/templates/input/shortTextInput/short-text-input.html',
link: FormControlService.link
})
在我的模板,我想以下几点:
include ../../input/_input-mixins.jade
+WrapInputwithLabelAndErrorplaceholder
div.inner-icon
div(class="{{ inputColumnsClass }}")
+InputwithValidation.item
不幸的是,我不能让这个列类露面,实际上在我的地优选的样式输入d方法。当我将这个类硬编码到我的模板中时,我打算做的工作就很好。
上我应该如何处理这个任何提示?
是的,这就是它!不能相信我错过了它。 –
@estus用这些信息写一个答案,以便未来的用户可以容易地接受和看到它。 –
@ArianFaurtosh当然。 – estus