diff --git a/packages/core/src/debug/debug_node.ts b/packages/core/src/debug/debug_node.ts index 313ebb163f..d0cb0ac07c 100644 --- a/packages/core/src/debug/debug_node.ts +++ b/packages/core/src/debug/debug_node.ts @@ -14,9 +14,9 @@ import {StylingMapArray, TStylingContext} from '../render3/interfaces/styling'; import {isComponentHost, isLContainer} from '../render3/interfaces/type_checks'; import {LView, PARENT, TData, TVIEW, T_HOST} from '../render3/interfaces/view'; import {NodeStylingDebug} from '../render3/styling/styling_debug'; -import {isStylingContext, stylingMapToStringMap} from '../render3/styling/util'; import {getComponent, getContext, getInjectionTokens, getInjector, getListeners, getLocalRefs, isBrowserEvents, loadLContext} from '../render3/util/discovery_utils'; import {INTERPOLATION_DELIMITER, renderStringify} from '../render3/util/misc_utils'; +import {isStylingContext, stylingMapToStringMap} from '../render3/util/styling_utils'; import {findComponentView} from '../render3/util/view_traversal_utils'; import {getComponentViewByIndex, getNativeByTNodeOrNull} from '../render3/util/view_utils'; import {assertDomNode} from '../util/assert'; diff --git a/packages/core/src/render3/di.ts b/packages/core/src/render3/di.ts index 933040d212..0fd81994ea 100644 --- a/packages/core/src/render3/di.ts +++ b/packages/core/src/render3/di.ts @@ -24,10 +24,10 @@ import {isComponentDef, isComponentHost} from './interfaces/type_checks'; import {DECLARATION_VIEW, INJECTOR, LView, TData, TVIEW, TView, T_HOST} from './interfaces/view'; import {assertNodeOfPossibleTypes} from './node_assert'; import {getLView, getPreviousOrParentTNode, setTNodeAndViewData} from './state'; -import {getInitialStylingValue} from './styling/util'; import {isNameOnlyAttributeMarker} from './util/attrs_utils'; import {getParentInjectorIndex, getParentInjectorView, hasParentInjector} from './util/injector_utils'; import {stringifyForError} from './util/misc_utils'; +import {getInitialStylingValue} from './util/styling_utils'; import {findComponentView} from './util/view_traversal_utils'; diff --git a/packages/core/src/render3/instructions/element.ts b/packages/core/src/render3/instructions/element.ts index 294ed48f89..5c4b7c5080 100644 --- a/packages/core/src/render3/instructions/element.ts +++ b/packages/core/src/render3/instructions/element.ts @@ -18,8 +18,8 @@ import {BINDING_INDEX, HEADER_OFFSET, LView, RENDERER, TVIEW, T_HOST} from '../i import {assertNodeType} from '../node_assert'; import {appendChild} from '../node_manipulation'; import {decreaseElementDepthCount, getElementDepthCount, getIsParent, getLView, getNamespace, getPreviousOrParentTNode, getSelectedIndex, increaseElementDepthCount, setIsNotParent, setPreviousOrParentTNode} from '../state'; -import {getInitialStylingValue, hasClassInput, hasStyleInput} from '../styling/util'; import {setUpAttributes} from '../util/attrs_utils'; +import {getInitialStylingValue, hasClassInput, hasStyleInput} from '../util/styling_utils'; import {getNativeByTNode, getTNode} from '../util/view_utils'; import {createDirectivesInstances, elementCreate, executeContentQueries, getOrCreateTNode, renderInitialStyling, resolveDirectives, saveResolvedLocalsInData, setInputsForProperty} from './shared'; diff --git a/packages/core/src/render3/instructions/lview_debug.ts b/packages/core/src/render3/instructions/lview_debug.ts index 2f9671f2bc..062c573b1b 100644 --- a/packages/core/src/render3/instructions/lview_debug.ts +++ b/packages/core/src/render3/instructions/lview_debug.ts @@ -21,8 +21,8 @@ import {RComment, RElement, RNode} from '../interfaces/renderer'; import {TStylingContext} from '../interfaces/styling'; import {BINDING_INDEX, CHILD_HEAD, CHILD_TAIL, CLEANUP, CONTEXT, DECLARATION_VIEW, ExpandoInstructions, FLAGS, HEADER_OFFSET, HOST, HookData, INJECTOR, LView, LViewFlags, NEXT, PARENT, QUERIES, RENDERER, RENDERER_FACTORY, SANITIZER, TData, TVIEW, TView as ITView, TView, T_HOST} from '../interfaces/view'; import {DebugStyling as DebugNewStyling, NodeStylingDebug} from '../styling/styling_debug'; -import {isStylingContext} from '../styling/util'; import {attachDebugObject} from '../util/debug_utils'; +import {isStylingContext} from '../util/styling_utils'; import {getTNode, unwrapRNode} from '../util/view_utils'; const NG_DEV_MODE = ((typeof ngDevMode === 'undefined' || !!ngDevMode) && initNgDevMode()); diff --git a/packages/core/src/render3/instructions/styling.ts b/packages/core/src/render3/instructions/styling.ts index 7bbdf0bd28..f299bed4d6 100644 --- a/packages/core/src/render3/instructions/styling.ts +++ b/packages/core/src/render3/instructions/styling.ts @@ -16,9 +16,9 @@ import {getActiveDirectiveId, getCurrentStyleSanitizer, getLView, getSelectedInd import {applyStylingMapDirectly, applyStylingValueDirectly, flushStyling, setClass, setStyle, updateClassViaContext, updateStyleViaContext} from '../styling/bindings'; import {activateStylingMapFeature} from '../styling/map_based_bindings'; import {attachStylingDebugObject} from '../styling/styling_debug'; -import {addItemToStylingMap, allocStylingMapArray, allocTStylingContext, allowDirectStyling, concatString, forceClassesAsString, forceStylesAsString, getInitialStylingValue, getStylingMapArray, hasClassInput, hasStyleInput, hasValueChanged, isContextLocked, isHostStylingActive, isStylingContext, normalizeIntoStylingMap, setValue, stylingMapToString} from '../styling/util'; import {NO_CHANGE} from '../tokens'; import {renderStringify} from '../util/misc_utils'; +import {addItemToStylingMap, allocStylingMapArray, allocTStylingContext, allowDirectStyling, concatString, forceClassesAsString, forceStylesAsString, getInitialStylingValue, getStylingMapArray, hasClassInput, hasStyleInput, hasValueChanged, isContextLocked, isHostStylingActive, isStylingContext, normalizeIntoStylingMap, setValue, stylingMapToString} from '../util/styling_utils'; import {getNativeByTNode, getTNode} from '../util/view_utils'; diff --git a/packages/core/src/render3/node_selector_matcher.ts b/packages/core/src/render3/node_selector_matcher.ts index 5098ae87ad..1fa461a2c8 100644 --- a/packages/core/src/render3/node_selector_matcher.ts +++ b/packages/core/src/render3/node_selector_matcher.ts @@ -12,8 +12,8 @@ import {assertDefined, assertNotEqual} from '../util/assert'; import {AttributeMarker, TAttributes, TNode, TNodeType, unusedValueExportToPlacateAjd as unused1} from './interfaces/node'; import {CssSelector, CssSelectorList, SelectorFlags, unusedValueExportToPlacateAjd as unused2} from './interfaces/projection'; -import {getInitialStylingValue} from './styling/util'; import {isNameOnlyAttributeMarker} from './util/attrs_utils'; +import {getInitialStylingValue} from './util/styling_utils'; const unusedValueToPlacateAjd = unused1 + unused2; diff --git a/packages/core/src/render3/styling/bindings.ts b/packages/core/src/render3/styling/bindings.ts index bf72b8b1bb..a81f1e4165 100644 --- a/packages/core/src/render3/styling/bindings.ts +++ b/packages/core/src/render3/styling/bindings.ts @@ -10,9 +10,9 @@ import {StyleSanitizeFn, StyleSanitizeMode} from '../../sanitization/style_sanit import {ProceduralRenderer3, RElement, Renderer3, RendererStyleFlags3, isProceduralRenderer} from '../interfaces/renderer'; import {ApplyStylingFn, LStylingData, StylingMapArray, StylingMapArrayIndex, StylingMapsSyncMode, SyncStylingMapsFn, TStylingConfig, TStylingContext, TStylingContextIndex, TStylingContextPropConfigFlags} from '../interfaces/styling'; import {NO_CHANGE} from '../tokens'; +import {DEFAULT_BINDING_INDEX, DEFAULT_BINDING_VALUE, DEFAULT_GUARD_MASK_VALUE, MAP_BASED_ENTRY_PROP_NAME, getBindingValue, getConfig, getDefaultValue, getGuardMask, getMapProp, getMapValue, getProp, getPropValuesStartPosition, getStylingMapArray, getTotalSources, getValue, getValuesCount, hasConfig, hasValueChanged, isContextLocked, isHostStylingActive, isSanitizationRequired, isStylingValueDefined, lockContext, patchConfig, setDefaultValue, setGuardMask, setMapAsDirty, setValue} from '../util/styling_utils'; import {getStylingState, resetStylingState} from './state'; -import {DEFAULT_BINDING_INDEX, DEFAULT_BINDING_VALUE, DEFAULT_GUARD_MASK_VALUE, MAP_BASED_ENTRY_PROP_NAME, getBindingValue, getConfig, getDefaultValue, getGuardMask, getMapProp, getMapValue, getProp, getPropValuesStartPosition, getStylingMapArray, getTotalSources, getValue, getValuesCount, hasConfig, hasValueChanged, isContextLocked, isHostStylingActive, isSanitizationRequired, isStylingValueDefined, lockContext, patchConfig, setDefaultValue, setGuardMask, setMapAsDirty, setValue} from './util'; diff --git a/packages/core/src/render3/styling/map_based_bindings.ts b/packages/core/src/render3/styling/map_based_bindings.ts index 38f3c61d41..709cc70f81 100644 --- a/packages/core/src/render3/styling/map_based_bindings.ts +++ b/packages/core/src/render3/styling/map_based_bindings.ts @@ -9,9 +9,9 @@ import {unwrapSafeValue} from '../../sanitization/bypass'; import {StyleSanitizeFn, StyleSanitizeMode} from '../../sanitization/style_sanitizer'; import {ProceduralRenderer3, RElement, Renderer3} from '../interfaces/renderer'; import {ApplyStylingFn, LStylingData, StylingMapArray, StylingMapArrayIndex, StylingMapsSyncMode, SyncStylingMapsFn, TStylingContext, TStylingContextIndex} from '../interfaces/styling'; +import {getBindingValue, getMapProp, getMapValue, getValue, getValuesCount, isStylingValueDefined} from '../util/styling_utils'; import {setStylingMapsSyncFn} from './bindings'; -import {getBindingValue, getMapProp, getMapValue, getValue, getValuesCount, isStylingValueDefined} from './util'; diff --git a/packages/core/src/render3/styling/state.ts b/packages/core/src/render3/styling/state.ts index 8cf06b3ea9..a160a9f999 100644 --- a/packages/core/src/render3/styling/state.ts +++ b/packages/core/src/render3/styling/state.ts @@ -6,7 +6,7 @@ * found in the LICENSE file at https://angular.io/license */ import {RElement} from '../interfaces/renderer'; -import {TEMPLATE_DIRECTIVE_INDEX} from './util'; +import {TEMPLATE_DIRECTIVE_INDEX} from '../util/styling_utils'; /** * -------- diff --git a/packages/core/src/render3/styling/styling_debug.ts b/packages/core/src/render3/styling/styling_debug.ts index 0c7c1504be..f7a4327ca3 100644 --- a/packages/core/src/render3/styling/styling_debug.ts +++ b/packages/core/src/render3/styling/styling_debug.ts @@ -10,10 +10,10 @@ import {RElement} from '../interfaces/renderer'; import {ApplyStylingFn, LStylingData, TStylingConfig, TStylingContext, TStylingContextIndex} from '../interfaces/styling'; import {getCurrentStyleSanitizer} from '../state'; import {attachDebugObject} from '../util/debug_utils'; +import {allowDirectStyling as _allowDirectStyling, getDefaultValue, getGuardMask, getProp, getPropValuesStartPosition, getValuesCount, hasConfig, isContextLocked, isMapBased, isSanitizationRequired} from '../util/styling_utils'; import {applyStylingViaContext} from './bindings'; import {activateStylingMapFeature} from './map_based_bindings'; -import {allowDirectStyling as _allowDirectStyling, getDefaultValue, getGuardMask, getProp, getPropValuesStartPosition, getValuesCount, hasConfig, isContextLocked, isMapBased, isSanitizationRequired} from './util'; diff --git a/packages/core/src/render3/styling/util.ts b/packages/core/src/render3/util/styling_utils.ts similarity index 100% rename from packages/core/src/render3/styling/util.ts rename to packages/core/src/render3/util/styling_utils.ts diff --git a/packages/core/test/render3/styling_next/map_based_bindings_spec.ts b/packages/core/test/render3/styling_next/map_based_bindings_spec.ts index f895aba302..0845a35815 100644 --- a/packages/core/test/render3/styling_next/map_based_bindings_spec.ts +++ b/packages/core/test/render3/styling_next/map_based_bindings_spec.ts @@ -5,7 +5,7 @@ * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */ -import {normalizeIntoStylingMap as createMap} from '../../../src/render3/styling/util'; +import {normalizeIntoStylingMap as createMap} from '../../../src/render3/util/styling_utils'; describe('map-based bindings', () => { describe('StylingMapArray construction', () => { diff --git a/packages/core/test/render3/styling_next/styling_context_spec.ts b/packages/core/test/render3/styling_next/styling_context_spec.ts index c4ba6186d9..1d103953d2 100644 --- a/packages/core/test/render3/styling_next/styling_context_spec.ts +++ b/packages/core/test/render3/styling_next/styling_context_spec.ts @@ -7,9 +7,8 @@ */ import {registerBinding} from '@angular/core/src/render3/styling/bindings'; import {attachStylingDebugObject} from '@angular/core/src/render3/styling/styling_debug'; -import {DEFAULT_GUARD_MASK_VALUE} from '@angular/core/src/render3/styling/util'; -import {allocTStylingContext} from '../../../src/render3/styling/util'; +import {DEFAULT_GUARD_MASK_VALUE, allocTStylingContext} from '../../../src/render3/util/styling_utils'; describe('styling context', () => { it('should register a series of entries into the context', () => { diff --git a/packages/core/test/render3/styling_next/styling_debug_spec.ts b/packages/core/test/render3/styling_next/styling_debug_spec.ts index 53237c8215..65ba95f4d0 100644 --- a/packages/core/test/render3/styling_next/styling_debug_spec.ts +++ b/packages/core/test/render3/styling_next/styling_debug_spec.ts @@ -7,7 +7,7 @@ */ import {registerBinding} from '@angular/core/src/render3/styling/bindings'; import {NodeStylingDebug, attachStylingDebugObject} from '@angular/core/src/render3/styling/styling_debug'; -import {allocTStylingContext} from '@angular/core/src/render3/styling/util'; +import {allocTStylingContext} from '@angular/core/src/render3/util/styling_utils'; describe('styling debugging tools', () => { describe('NodeStylingDebug', () => {