11/*
2- * Copyright (c) 2018, salesforce.com, inc .
2+ * Copyright (c) 2025, Salesforce, Inc .
33 * All rights reserved.
44 * SPDX-License-Identifier: MIT
55 * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
@@ -20,12 +20,11 @@ import { logError } from '../shared/logger';
2020
2121import api from './api' ;
2222import { RenderMode , ShadowMode } from './vm' ;
23- import { computeHasScopedStyles , hasStyles } from './template' ;
23+ import { hasStyles } from './template' ;
2424import { getStyleOrSwappedStyle } from './hot-swaps' ;
2525import { checkVersionMismatch } from './check-version-mismatch' ;
26- import { getComponentInternalDef } from './def' ;
2726import { assertNotProd , EmptyArray } from './utils' ;
28- import type { VCustomElement , VNode } from './vnodes' ;
27+ import type { VNode } from './vnodes' ;
2928import type { Template } from './template' ;
3029import type { VM } from './vm' ;
3130import type { Stylesheet , Stylesheets } from '@lwc/shared' ;
@@ -321,22 +320,6 @@ export function getScopeTokenClass(owner: VM, legacy: boolean): string | null {
321320 ) ;
322321}
323322
324- /**
325- * This function returns the host style token for a custom element if it
326- * exists. Otherwise it returns null.
327- *
328- * A host style token is applied to the component if scoped styles are used.
329- * @param vnode
330- */
331- export function getStylesheetTokenHost ( vnode : VCustomElement ) : string | null {
332- const { template } = getComponentInternalDef ( vnode . ctor ) ;
333- const { vm } = vnode ;
334- const { stylesheetToken } = template ;
335- return ! isUndefined ( stylesheetToken ) && computeHasScopedStyles ( template , vm )
336- ? makeHostToken ( stylesheetToken )
337- : null ;
338- }
339-
340323function getNearestNativeShadowComponent ( vm : VM ) : VM | null {
341324 const owner = getNearestShadowComponent ( vm ) ;
342325 if ( ! isNull ( owner ) && owner . shadowMode === ShadowMode . Synthetic ) {
0 commit comments