File tree Expand file tree Collapse file tree 4 files changed +12
-8
lines changed
src/components/primitives Expand file tree Collapse file tree 4 files changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -12,22 +12,26 @@ export default {
12
12
customSize: String ,
13
13
fill: {
14
14
type: String ,
15
- }
15
+ },
16
+ cacheVersion: {
17
+ type: String ,
18
+ default: ' 1.0.0' ,
19
+ },
16
20
},
17
21
setup (props ) {
18
22
const shouldIconClass = computed (() => ! props .customSize && ! props .customClass )
19
23
// Only apply 100% size when bulma icon class is used
20
- const computedHeight = computed (() => ! shouldIconClass .value ? props .customSize : " 100%" )
21
- const computedWidth = computed (() => ! shouldIconClass .value ? props .customSize : " 100%" )
24
+ const computedHeight = computed (() => ( ! shouldIconClass .value ? props .customSize : ' 100%' ) )
25
+ const computedWidth = computed (() => ( ! shouldIconClass .value ? props .customSize : ' 100%' ) )
22
26
return { computedHeight, computedWidth, shouldIconClass }
23
27
},
24
28
}
25
29
</script >
26
30
27
31
<template >
28
- <span :class =" [{'icon': shouldIconClass}, size]" >
32
+ <span :class =" [{ 'icon': shouldIconClass }, size]" >
29
33
<svg :fill =" fill" :height =" computedHeight" :width =" computedWidth" :class =" [customClass]" >
30
- <use :href =" `/${bundle}.svg#${name}`" />
34
+ <use :href =" `/${bundle}.svg?v=${cacheVersion} #${name}`" />
31
35
</svg >
32
36
</span >
33
37
</template >
Original file line number Diff line number Diff line change 1
1
// Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
3
- exports [` Icon render correctly 1` ] = ` <span class = " icon" ><svg height = " 100%" width = " 100%" class = " " ><use href = " /undefined.svg#undefined" ></use ></svg ></span >` ;
3
+ exports [` Icon render correctly 1` ] = ` <span class = " icon" ><svg height = " 100%" width = " 100%" class = " " ><use href = " /undefined.svg?v=1.0.0 #undefined" ></use ></svg ></span >` ;
Original file line number Diff line number Diff line change 1
1
// Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
3
- exports [` Image render correctly 1` ] = ` <figure class = " image" ><img class = " img" ></figure >`;
3
+ exports [` Image render correctly 1` ] = ` <figure class = " image figure " ><img class = " img" ></figure >`;
Original file line number Diff line number Diff line change 1
1
// Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
3
- exports [` Timeline render correctly 1` ] = ` <ol class = " px-5 timeline" ></ol >` ;
3
+ exports [` Timeline render correctly 1` ] = ` <ol class = " timeline" ></ol >` ;
You can’t perform that action at this time.
0 commit comments