import { inject } from '@angular/core';
import { TabService } from './tab';

/**
 * Injects the current activated tab as a signal.
 * @returns A signal that emits the current activated tab or null if no tab is activated.
 */
export function injectTab() {
  return inject(TabService).activatedTab;
}

/**
 * Injects the current tab ID as a signal.
 * @returns A signal that emits the current tab ID or null if no tab is activated.
 */
export function injectTabId() {
  return inject(TabService).activatedTabId;
}
