File tree 3 files changed +6
-2
lines changed
3 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 8
8
lit-html directive that removes and attribute if it is undefined
9
9
*/
10
10
export default directive ( value => part => {
11
- if ( ( value === undefined || value === null || value === "" ) && part instanceof AttributePart ) {
11
+ if ( ( value === undefined ) && part instanceof AttributePart ) {
12
12
if ( value !== part . value ) {
13
13
const name = part . committer . name ;
14
14
part . committer . element . removeAttribute ( name ) ;
Original file line number Diff line number Diff line change 1
1
<a
2
2
class =" {{ classes.main }} "
3
3
role =" link"
4
- href =" {{ href }} "
4
+ href =" {{ parsedRef }} "
5
5
target =" {{ target }} "
6
6
rel =" {{ _rel }} "
7
7
tabindex =" {{ tabIndex }} "
Original file line number Diff line number Diff line change @@ -263,6 +263,10 @@ class Link extends UI5Element {
263
263
} ,
264
264
} ;
265
265
}
266
+
267
+ get parsedRef ( ) {
268
+ return this . href . length > 0 ? this . href : undefined ;
269
+ }
266
270
}
267
271
268
272
Bootstrap . boot ( ) . then ( _ => {
You can’t perform that action at this time.
0 commit comments