A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/bootstrap-vue/bootstrap-vue/commit/927c234a6b5d68e23e86f7d1782b179b1ccb8786 below:

additional adjustment for stacked animations (#4948) · bootstrap-vue/bootstrap-vue@927c234 · GitHub

File tree Expand file treeCollapse file tree 2 files changed

+38

-0

lines changed

Filter options

Expand file treeCollapse file tree 2 files changed

+38

-0

lines changed Original file line number Diff line number Diff line change

@@ -116,6 +116,12 @@ export const BVIconBase = /*#__PURE__*/ Vue.extend({

116 116

)

117 117

}

118 118 119 +

if (isStacked) {

120 +

// Wrap in an additional `<g>` for proper

121 +

// animation handling if stacked

122 +

$inner = h('g', {}, [$inner])

123 +

}

124 + 119 125

return h(

120 126

'svg',

121 127

mergeData(

Original file line number Diff line number Diff line change

@@ -52,6 +52,38 @@ describe('icons', () => {

52 52

expect(wrapper.find('svg > g > path').exists()).toBe(true)

53 53

})

54 54 55 +

it('b-icon has expected structure when `stacked` prop is true', async () => {

56 +

const wrapper = mount(BIcon, {

57 +

localVue: localVue,

58 +

parentComponent: parentComponent,

59 +

propsData: {

60 +

icon: 'alert-circle-fill',

61 +

stacked: true

62 +

}

63 +

})

64 + 65 +

expect(wrapper.exists()).toBe(true)

66 +

expect(wrapper.is('svg')).toBe(true)

67 +

expect(wrapper.classes()).toContain('b-icon')

68 +

expect(wrapper.classes()).toContain('bi')

69 +

expect(wrapper.classes()).toContain('bi-alert-circle-fill')

70 +

expect(wrapper.classes().length).toBe(3)

71 +

expect(wrapper.attributes('role')).not.toBe('img')

72 +

expect(wrapper.attributes('alt')).not.toBe('icon')

73 +

expect(wrapper.attributes('focusable')).toBe('false')

74 +

expect(wrapper.attributes('xmlns')).not.toBe('http://www.w3.org/2000/svg')

75 +

expect(wrapper.attributes('width')).not.toBe('1em')

76 +

expect(wrapper.attributes('height')).not.toBe('1em')

77 +

expect(wrapper.attributes('viewBox')).toBe('0 0 20 20')

78 +

expect(wrapper.attributes('fill')).toBe('currentColor')

79 +

expect(wrapper.attributes('style')).not.toBeDefined()

80 +

expect(wrapper.element.style.fontSize).toEqual('')

81 +

expect(wrapper.find('svg > g').exists()).toBe(true)

82 +

expect(wrapper.find('svg > g').attributes('transform')).not.toBeDefined()

83 +

expect(wrapper.find('svg > g > path').exists()).toBe(false)

84 +

expect(wrapper.find('svg > g > g > path').exists()).toBe(true)

85 +

})

86 + 55 87

it('b-icon with empty icon name renders BIconBlank', async () => {

56 88

// This test assumes Vue doesn't puke on unknown component names

57 89

// As we don't specify a parent instance (which has all the registered

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4