mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-16 01:52:19 +08:00
test(tabs): re-enable skipped tests (#29813)
Co-authored-by: Brandy Carney <brandyscarney@users.noreply.github.com>
This commit is contained in:
@ -50,15 +50,23 @@ export const IonTabs = /*@__PURE__*/ defineComponent({
|
||||
name: "IonTabs",
|
||||
emits: [WILL_CHANGE, DID_CHANGE],
|
||||
setup(props, { slots, emit }) {
|
||||
// Define the custom element
|
||||
defineCustomElement();
|
||||
|
||||
return {
|
||||
props,
|
||||
slots,
|
||||
emit,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
/**
|
||||
* `defineCustomElement` must be called in the `mounted` hook
|
||||
* to ensure that the custom element is defined after the
|
||||
* component has been fully rendered and initialized.
|
||||
* This prevents issues with undefined properties, like
|
||||
* `selectedTab` from core, which may occur if the custom
|
||||
* element is defined too early in the component's lifecycle.
|
||||
*/
|
||||
defineCustomElement();
|
||||
},
|
||||
render() {
|
||||
const { slots, emit, props } = this;
|
||||
const slottedContent = slots.default && slots.default();
|
||||
|
Reference in New Issue
Block a user