This repository was archived by the owner on Mar 27, 2025. It is now read-only.
File tree 3 files changed +4
-24
lines changed
packages/bootstrap-vue-next/src/components
3 files changed +4
-24
lines changed Original file line number Diff line number Diff line change @@ -111,10 +111,10 @@ const loadingBoolean = useBooleanish(() => props.loading)
111
111
112
112
const isToggle = computed <boolean >(() => typeof pressedBoolean .value === ' boolean' )
113
113
const isButton = computed <boolean >(
114
- () => props .tag === ' button' && props .href === undefined && props .to === null
114
+ () => props .tag === ' button' && props .href === undefined && props .to === undefined
115
115
)
116
116
const computedLink = computed <boolean >(() => isLink (props ))
117
- const isBLink = computed <boolean >(() => props .to !== null )
117
+ const isBLink = computed <boolean >(() => props .to !== undefined )
118
118
const nonStandardTag = computed <boolean >(() => (props .href !== undefined ? false : ! isButton .value ))
119
119
120
120
const computedClasses = computed (() => [
Original file line number Diff line number Diff line change @@ -190,26 +190,6 @@ describe('form-input', () => {
190
190
expect ( $input . attributes ( 'type' ) ) . toBe ( 'number' )
191
191
} )
192
192
193
- it ( 'renders text input when type not supported' , ( ) => {
194
- const warnHandler = vitest . fn ( )
195
-
196
- const wrapper = mount ( BFormInput , {
197
- global : {
198
- config : {
199
- warnHandler,
200
- } ,
201
- } ,
202
- props : {
203
- type : 'foobar' ,
204
- } ,
205
- } )
206
-
207
- const $input = wrapper . get ( 'input' )
208
- expect ( $input . attributes ( 'type' ) ) . toBe ( 'text' )
209
-
210
- expect ( warnHandler ) . toHaveBeenCalled ( )
211
- } )
212
-
213
193
it ( 'does not have is-valid or is-invalid classes when state is default' , ( ) => {
214
194
const wrapper = mount ( BFormInput )
215
195
Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ const props = withDefaults(defineProps<BLinkProps>(), {
51
51
routerTag: ' a' ,
52
52
target: ' _self' ,
53
53
to: undefined ,
54
- variant: undefined ,
54
+ variant: null ,
55
55
opacity: undefined ,
56
56
opacityHover: undefined ,
57
57
underlineVariant: null ,
@@ -142,7 +142,7 @@ const routerAttr = computed(() => ({
142
142
' to' : props .to ,
143
143
' href' : computedHref .value ,
144
144
' target' : props .target ,
145
- ' rel' : props .target === ' _blank' && props .rel === null ? ' noopener' : props .rel || null ,
145
+ ' rel' : props .target === ' _blank' && props .rel === undefined ? ' noopener' : props .rel || undefined ,
146
146
' tabindex' : disabledBoolean .value
147
147
? ' -1'
148
148
: typeof attrs .tabindex === ' undefined'
You can’t perform that action at this time.
0 commit comments