.flex-container {
display: flex;
text-overflow: ellipsis;
overflow: hidden;
text-align: left;
}Run Code Online (Sandbox Code Playgroud)
<h1>Flexible Boxes</h1>
<div class="flex-container" style="height: 12%; width:14%">
ThisIsASampleText
</div>Run Code Online (Sandbox Code Playgroud)
Output: ThisIsASamp
Expected: ThisIsASam...
Run Code Online (Sandbox Code Playgroud)
当我删除flex属性时,它工作正常。
我想知道为什么柔韧性会影响省略号。
TIA
我在使用自定义 Angular 元素时卡住了,每当我发出一个值 ie trueor 时false,它element在同一个 angular 项目中使用时都能正常工作,每当我通过创建其捆绑JS文件在其他项目中使用该元素时。它显示Inputs events在父组件中。
这是我在父组件中的 Angular 元素
<app-address [model]="address" [isAddressValid]="isValid"
(getValidity)="getValue($event)" placeholder="placeholder" label="label" isRequired="false" ></app-address>
Run Code Online (Sandbox Code Playgroud)
在父组件中,我正在访问类似的值
getValue(data) {
console.log(data)
}
Run Code Online (Sandbox Code Playgroud)
而不是显示发出的数据 ietrue或false它的显示我inputs事件。
这就是我导入文件的方式
import '../../../Elements/angular-address-element/elements/app-address-element'
Run Code Online (Sandbox Code Playgroud)
子组件
@Output() getValidity = new EventEmitter<any>();
this.getValidity.emit(true)
Run Code Online (Sandbox Code Playgroud)
我emit在change活动中调用它。