From cc8419e8e679cb44be7b82397a729a6230ab3c74 Mon Sep 17 00:00:00 2001 From: DjDeveloperr Date: Wed, 22 Apr 2026 00:45:12 -0400 Subject: [PATCH] Remove obsolete NativeScript build artifacts --- .github/workflows/ci.yml | 2 +- .github/workflows/npm_napi_release.yml | 46 +- .github/workflows/npm_release.yml | 17 +- .gitignore | 8 +- .travis.yml | 21 - .../TNSWidgets.xcframework/Info.plist | 40 - .../Headers/NSData+Async.h | 24 - .../Headers/NSString+Async.h | 25 - .../TNSWidgets.framework/Headers/TNSLabel.h | 16 - .../TNSWidgets.framework/Headers/TNSProcess.h | 29 - .../TNSWidgets.framework/Headers/TNSWidgets.h | 24 - .../Headers/UIImage+TNSBlocks.h | 26 - .../Headers/UIView+PassThroughParent.h | 17 - .../ios-arm64/TNSWidgets.framework/Info.plist | Bin 789 -> 0 bytes .../Modules/module.modulemap | 6 - .../PrivateHeaders/NSObject+Swizzling.h | 17 - .../PrivateHeaders/UIView+PropertyBag.h | 18 - .../ios-arm64/TNSWidgets.framework/TNSWidgets | Bin 190408 -> 0 bytes .../Headers/NSData+Async.h | 24 - .../Headers/NSString+Async.h | 25 - .../TNSWidgets.framework/Headers/TNSLabel.h | 16 - .../TNSWidgets.framework/Headers/TNSProcess.h | 29 - .../TNSWidgets.framework/Headers/TNSWidgets.h | 24 - .../Headers/UIImage+TNSBlocks.h | 26 - .../Headers/UIView+PassThroughParent.h | 17 - .../TNSWidgets.framework/Info.plist | Bin 769 -> 0 bytes .../Modules/module.modulemap | 6 - .../PrivateHeaders/NSObject+Swizzling.h | 17 - .../PrivateHeaders/UIView+PropertyBag.h | 18 - .../TNSWidgets.framework/TNSWidgets | Bin 159904 -> 0 bytes .../_CodeSignature/CodeResources | 252 - AppWithModules/Info.plist | 37 - AppWithModules/Source Files/main.m | 32 - AppWithModules/app/bundle.js | 394 - AppWithModules/app/package.json | 7 - AppWithModules/app/runtime.js | 829 - .../tns-core-modules/inspector_modules.js | 12 - AppWithModules/app/vendor.js | 136891 --------------- NativeScript/CMakeLists.txt | 29 + NativeScript/ffi/Block.mm | 67 +- NativeScript/ffi/Cif.mm | 3 + NativeScript/ffi/Class.h | 1 + NativeScript/ffi/Class.mm | 39 +- NativeScript/ffi/ClassMember.mm | 30 +- NativeScript/ffi/Closure.h | 5 + NativeScript/ffi/Closure.mm | 20 +- NativeScript/ffi/Interop.h | 8 +- NativeScript/ffi/Interop.mm | 90 +- NativeScript/ffi/JSObject.mm | 2 +- NativeScript/ffi/ObjCBridge.h | 189 +- NativeScript/ffi/ObjCBridge.mm | 115 +- NativeScript/ffi/Object.mm | 43 +- NativeScript/ffi/ObjectRef.mm | 17 +- NativeScript/ffi/Protocol.h | 4 + NativeScript/ffi/Protocol.mm | 13 +- NativeScript/ffi/Struct.h | 4 + NativeScript/ffi/Struct.mm | 31 +- NativeScript/ffi/TypeConv.mm | 73 +- NativeScript/libffi/iphoneos-arm64/libffi.a | Bin 55312 -> 55312 bytes .../libffi/iphonesimulator-universal/libffi.a | Bin 97760 -> 97760 bytes NativeScript/libffi/macosx-universal/libffi.a | Bin 101312 -> 101312 bytes NativeScript/libffi/xros-arm64/include/ffi.h | 524 + .../libffi/xros-arm64/include/ffitarget.h | 92 + NativeScript/libffi/xros-arm64/libffi.a | Bin 0 -> 55312 bytes .../libffi/xrsimulator-arm64/include/ffi.h | 524 + .../xrsimulator-arm64/include/ffitarget.h | 92 + .../libffi/xrsimulator-arm64/libffi.a | Bin 0 -> 55192 bytes NativeScript/napi/v8/jsr.cpp | 2 - NativeScript/napi/v8/v8-api.cpp | 41 +- NativeScript/runtime/modules/timers/Timers.mm | 92 +- NativeScriptRuntime.xcodeproj/project.pbxproj | 524 +- README.md | 23 +- TestRunner/Default-568h@2x.png | Bin 18594 -> 0 bytes .../app/tests/Infrastructure/simulator.js | 9 - TestRunnerTests/Embassy/Atomic.swift | 87 - .../Embassy/DefaultHTTPServer.swift | 112 - .../Embassy/DefaultLogFormatter.swift | 15 - TestRunnerTests/Embassy/DefaultLogger.swift | 112 - TestRunnerTests/Embassy/Embassy.h | 19 - TestRunnerTests/Embassy/Errors.swift | 23 - TestRunnerTests/Embassy/EventLoop.swift | 54 - TestRunnerTests/Embassy/FileLogHandler.swift | 40 - TestRunnerTests/Embassy/HTTPConnection.swift | 268 - .../Embassy/HTTPHeaderParser.swift | 87 - TestRunnerTests/Embassy/HTTPRequest.swift | 90 - TestRunnerTests/Embassy/HTTPServer.swift | 24 - TestRunnerTests/Embassy/HeapSort.swift | 91 - TestRunnerTests/Embassy/IOUtils.swift | 34 - TestRunnerTests/Embassy/KqueueSelector.swift | 180 - TestRunnerTests/Embassy/LogFormatter.swift | 14 - TestRunnerTests/Embassy/LogHandler.swift | 17 - TestRunnerTests/Embassy/Logger.swift | 70 - TestRunnerTests/Embassy/MultiDictionary.swift | 114 - TestRunnerTests/Embassy/PrintLogHandler.swift | 24 - .../Embassy/PropagateLogHandler.swift | 23 - TestRunnerTests/Embassy/SWSGI.swift | 35 - TestRunnerTests/Embassy/SWSGIUtils.swift | 59 - TestRunnerTests/Embassy/SelectSelector.swift | 119 - TestRunnerTests/Embassy/Selector.swift | 55 - .../Embassy/SelectorEventLoop.swift | 260 - TestRunnerTests/Embassy/SystemLibrary.swift | 197 - TestRunnerTests/Embassy/TCPSocket.swift | 300 - .../Embassy/TransformLogHandler.swift | 25 - TestRunnerTests/Embassy/Transport.swift | 209 - TestRunnerTests/Info.plist | 22 - TestRunnerTests/TestRunnerTests.m | 36 - TestRunnerTests/TestRunnerTests.swift | 68 - TestRunnerUITests/TestRunnerUITests.m | 44 - .../TestRunnerUITestsLaunchTests.m | 37 - build_all_macos.sh | 16 - build_all_react_native.sh | 3 - build_all_vision.sh | 10 - build_npm_ios.sh | 36 - build_npm_macos.sh | 36 - build_npm_node_api.sh | 15 - build_npm_vision.sh | 36 - metadata-generator/README.md | 2 +- package.json | 40 +- packages/{objc => ios-node-api}/LICENSE | 0 packages/ios-node-api/README.md | 47 + packages/{ios => ios-node-api}/deno.json | 0 packages/{ios => ios-node-api}/index.d.ts | 0 packages/{ios => ios-node-api}/index.js | 0 packages/{ios => ios-node-api}/mod.ts | 0 packages/ios-node-api/package.json | 59 + packages/ios/LICENSE | 220 +- packages/ios/README.md | 46 +- packages/ios/package.json | 67 +- packages/{macos => macos-node-api}/.gitignore | 0 packages/macos-node-api/LICENSE | 19 + packages/macos-node-api/README.md | 41 + packages/{macos => macos-node-api}/deno.json | 0 packages/{macos => macos-node-api}/index.cjs | 0 packages/{macos => macos-node-api}/index.d.ts | 0 packages/{macos => macos-node-api}/index.mjs | 0 packages/{macos => macos-node-api}/mod.ts | 0 packages/macos-node-api/package.json | 64 + packages/macos/LICENSE | 220 +- packages/macos/README.md | 40 +- .../NativeScript.framework/Versions/A | 1 - packages/macos/package.json | 72 +- packages/objc-node-api/LICENSE | 19 + packages/{objc => objc-node-api}/README.md | 0 packages/{objc => objc-node-api}/index.d.ts | 0 packages/{objc => objc-node-api}/index.js | 0 .../inline_functions.d.ts | 0 packages/{objc => objc-node-api}/package.json | 2 +- packages/visionos/LICENSE | 201 + packages/visionos/README.md | 13 + packages/visionos/package.json | 26 + prepare-target.js | 16 - run-tests.js | 128 - build_all_ios.sh => scripts/build_all_ios.sh | 20 +- scripts/build_all_macos.sh | 16 + .../build_all_node_api.sh | 10 +- scripts/build_all_react_native.sh | 5 + scripts/build_all_vision.sh | 24 + scripts/build_libffi.js | 66 + build_libffi.sh => scripts/build_libffi.sh | 3 +- .../build_metadata_generator.sh | 0 .../build_nativescript.sh | 41 +- scripts/build_npm_ios.sh | 39 + scripts/build_npm_macos.sh | 39 + scripts/build_npm_node_api.sh | 14 + scripts/build_npm_vision.sh | 39 + .../build_testrunner.sh | 1 + .../build_tklivesync.sh | 43 +- build_utils.sh => scripts/build_utils.sh | 6 +- scripts/build_xcframework.mts | 4 +- .../download_hermes.sh | 0 download_llvm.sh => scripts/download_llvm.sh | 0 download_v8.sh => scripts/download_v8.sh | 0 scripts/get-next-version.js | 32 +- scripts/get-npm-tag.js | 34 +- prepare_dSYMs.sh => scripts/prepare_dSYMs.sh | 4 +- scripts/run-tests-ios.js | 94 +- scripts/run-tests-macos.js | 14 +- scripts/testesm.sh | 6 + scripts/update_version.sh | 26 + .../project.pbxproj | 0 .../xcschemes/__PROJECT_NAME__.xcscheme | 0 .../__PROJECT_NAME__-Prefix.pch | 0 .../__PROJECT_NAME__.entitlements | 0 .../__PROJECT_NAME__/build-debug.xcconfig | 0 .../__PROJECT_NAME__/build-release.xcconfig | 0 .../ios}/__PROJECT_NAME__/build.xcconfig | 0 .../en.lproj/InfoPlist.strings | 0 .../ios}/internal/NativeScriptStart.h | 0 .../ios}/internal/NativeScriptStart.m | 0 .../ios}/internal/README.md | 0 .../internal/Swift-ObjC-Bridging-Header.h | 0 .../ios}/internal/macros.h | 0 .../ios}/internal/main.m | 0 .../ios}/internal/nativescript-build.xcconfig | 0 .../ios}/internal/nativescript-post-build | 0 .../ios}/internal/nativescript-pre-build | 0 .../ios}/internal/nativescript-pre-link | 0 .../ios}/internal/nsld.sh | 0 .../strip-dynamic-framework-architectures.sh | 0 .../project.pbxproj | 0 .../contents.xcworkspacedata | 0 .../xcschemes/__PROJECT_NAME__.xcscheme | 0 .../__PROJECT_NAME__-Prefix.pch | 0 .../__PROJECT_NAME__.entitlements | 0 .../__PROJECT_NAME__/build-debug.xcconfig | 0 .../__PROJECT_NAME__/build-release.xcconfig | 0 .../macos}/__PROJECT_NAME__/build.xcconfig | 0 .../en.lproj/InfoPlist.strings | 0 .../macos}/internal/NativeScriptStart.h | 0 .../macos}/internal/NativeScriptStart.m | 0 .../macos}/internal/README.md | 0 .../internal/Swift-ObjC-Bridging-Header.h | 0 .../macos}/internal/macros.h | 0 .../macos}/internal/main.m | 0 .../internal/nativescript-build.xcconfig | 0 .../macos}/internal/nativescript-post-build | 0 .../macos}/internal/nativescript-pre-build | 0 .../macos}/internal/nativescript-pre-link | 0 .../macos}/internal/nsld.sh | 0 .../strip-dynamic-framework-architectures.sh | 0 .../project.pbxproj | 0 .../xcschemes/__PROJECT_NAME__.xcscheme | 0 .../__PROJECT_NAME__-Prefix.pch | 0 .../__PROJECT_NAME__.entitlements | 0 .../__PROJECT_NAME__/build-debug.xcconfig | 0 .../__PROJECT_NAME__/build-release.xcconfig | 0 .../visionos}/__PROJECT_NAME__/build.xcconfig | 0 .../en.lproj/InfoPlist.strings | 0 .../visionos}/internal/NativeScriptStart.h | 0 .../visionos}/internal/NativeScriptStart.m | 0 .../visionos}/internal/README.md | 0 .../internal/Swift-ObjC-Bridging-Header.h | 0 .../visionos}/internal/macros.h | 0 .../internal/nativescript-build.xcconfig | 0 .../internal/nativescript-post-build | 0 .../visionos}/internal/nativescript-pre-build | 0 .../visionos}/internal/nativescript-pre-link | 0 .../visionos}/internal/nsld.sh | 0 .../strip-dynamic-framework-architectures.sh | 0 {cli_tests => test/cli}/assets/icon.png | Bin .../cli}/benchmark/foundation_calls.js | 0 .../cli}/benchmark/run_foundation_bench.js | 0 {cli_tests => test/cli}/error.js | 0 {cli_tests => test/cli}/esm_a.mjs | 0 {cli_tests => test/cli}/esm_b.mjs | 0 {cli_tests => test/cli}/gc.js | 0 {cli_tests => test/cli}/gc2.js | 0 {cli_tests => test/cli}/index.js | 0 {cli_tests => test/cli}/main_worker.js | 2 +- {cli_tests => test/cli}/memory/_harness.js | 0 .../cli}/memory/_plain_harness.js | 0 .../memory/appkit_navigation_visual_demo.js | 0 .../cli}/memory/run_memory_semantics_tests.js | 0 .../cli}/memory/run_memory_tests.js | 0 .../memory/run_memory_tests_all_engines.sh | 4 +- .../memory/test_appkit_navigation_extreme.js | 0 .../test_appkit_navigation_throughput.js | 0 .../test_block_callback_finalization.js | 0 .../memory/test_block_completion_safety.js | 0 .../cli}/memory/test_block_lifecycle.js | 0 .../test_c_function_pointer_semantics.js | 0 .../memory/test_dispatch_async_background.js | 0 .../cli}/memory/test_js_heap_throughput.js | 0 .../cli}/memory/test_mixed_stress.js | 0 .../cli}/memory/test_objc_ownership_rules.js | 0 .../cli}/memory/test_objc_wrapper_churn.js | 0 .../memory/test_objc_wrapper_finalization.js | 0 .../memory/test_plain_script_runloop_drain.js | 0 .../memory/test_pointer_c_buffer_semantics.js | 0 .../cli}/memory/test_reference_lifecycle.js | 0 .../cli}/memory/test_runloop_pending_work.js | 0 .../cli}/memory/test_weakref_finalization.js | 0 .../cli}/memory/test_weakref_plain_script.js | 0 {cli_tests => test/cli}/module_a.js | 0 {cli_tests => test/cli}/node_api/.gitignore | 0 {cli_tests => test/cli}/node_api/addon.cpp | 0 .../cli}/node_api/build_addon.sh | 4 +- .../cli}/node_api/cleanup_teardown.js | 0 .../cli}/node_api/reentry_tsfn.js | 0 .../cli}/node_api/run_teardown_test.sh | 4 +- {cli_tests => test/cli}/threadsafe.js | 0 .../cli}/view_controller_app.js | 0 {cli_tests => test/cli}/vm.js | 0 {cli_tests => test/cli}/worker.js | 0 .../runtime/fixtures}/Api/TNSApi.h | 0 .../runtime/fixtures}/Api/TNSApi.m | 0 .../runtime/fixtures}/Api/TNSBridgedTypes.h | 0 .../runtime/fixtures}/Api/TNSBridgedTypes.m | 0 .../fixtures}/Api/TNSDeclarationConflicts.h | 0 .../fixtures}/Api/TNSDeclarationConflicts.m | 0 .../fixtures}/Api/TNSPseudoDataTypes.h | 0 .../fixtures}/Api/TNSPseudoDataTypes.m | 0 .../fixtures}/Api/TNSReturnsRetained.h | 0 .../fixtures}/Api/TNSReturnsRetained.m | 0 .../fixtures}/Api/TNSReturnsUnmanaged.h | 0 .../fixtures}/Api/TNSReturnsUnmanaged.m | 0 .../runtime/fixtures}/Api/TNSVersions.h | 0 .../runtime/fixtures}/Api/TNSVersions.m | 0 .../fixtures}/Functions/TNSFunctions.h | 0 .../fixtures}/Functions/TNSFunctions.m | 0 .../Interfaces/TNSClassWithPlaceholder.h | 0 .../Interfaces/TNSClassWithPlaceholder.m | 0 .../Interfaces/TNSConstructorResolution.h | 0 .../Interfaces/TNSConstructorResolution.m | 0 .../fixtures}/Interfaces/TNSInheritance.h | 0 .../fixtures}/Interfaces/TNSInheritance.m | 0 .../fixtures}/Interfaces/TNSMethodCalls.h | 0 .../fixtures}/Interfaces/TNSMethodCalls.m | 0 .../fixtures}/Interfaces/TNSSwiftLike.h | 0 .../fixtures}/Interfaces/TNSSwiftLike.m | 0 .../fixtures}/Marshalling/TNSAllocLog.h | 0 .../fixtures}/Marshalling/TNSAllocLog.m | 0 .../Marshalling/TNSFunctionPointers.h | 0 .../Marshalling/TNSFunctionPointers.m | 0 .../fixtures}/Marshalling/TNSObjCTypes.h | 0 .../fixtures}/Marshalling/TNSObjCTypes.m | 0 .../Marshalling/TNSPrimitivePointers.h | 0 .../Marshalling/TNSPrimitivePointers.m | 0 .../fixtures}/Marshalling/TNSPrimitives.h | 0 .../fixtures}/Marshalling/TNSPrimitives.m | 0 .../fixtures}/Marshalling/TNSRecords.h | 0 .../fixtures}/Marshalling/TNSRecords.m | 0 .../runtime/fixtures}/TNSTestCommon.h | 0 .../runtime/fixtures}/TNSTestCommon.m | 0 .../fixtures}/TNSTestNativeCallbacks.h | 0 .../fixtures}/TNSTestNativeCallbacks.m | 0 .../runtime/fixtures}/TestFixtures-Prefix.h | 0 .../runtime/fixtures}/TestFixtures.h | 0 .../runtime/fixtures}/exported-symbols.txt | 0 .../runtime/fixtures}/module.modulemap | 0 .../AccentColor.colorset/Contents.json | 0 .../AppIcon.appiconset/Contents.json | 0 .../runner}/Assets.xcassets/Contents.json | 0 .../runtime/runner}/Default-568h@2x.png | Bin .../runtime/runner}/Info.plist | 0 .../runtime/runner}/Source Files/main.m | 0 .../runtime/runner}/app/index.js | 0 .../runtime/runner}/app/package.json | 0 .../runtime/runner}/app/tests/.gitignore | 0 .../runtime/runner}/app/tests/ApiTests.js | 87 +- .../runner}/app/tests/DeclarationConflicts.js | 0 .../app/tests/ExceptionHandlingTests.js | 0 .../runner}/app/tests/FunctionsTests.js | 0 .../Jasmine/jasmine-2.0.1/boot.js | 0 .../Jasmine/jasmine-2.0.1/jasmine.js | 2 +- .../jasmine-reporters/junit_reporter.js | 0 .../jasmine-reporters/terminal_reporter.js | 0 .../tests/Infrastructure/Jasmine/jasmine.d.ts | 0 .../app/tests/Infrastructure/simulator.js | 39 + .../app/tests/Infrastructure/timers.js | 0 .../runner}/app/tests/Infrastructure/utf8.js | 0 .../app/tests/Inheritance/InheritanceTests.js | 0 .../ProtocolImplementationTests.js | 0 .../app/tests/Inheritance/TypeScriptTests.js | 0 .../app/tests/Inheritance/TypeScriptTests.ts | 0 .../app/tests/Marshalling/ConstantsTests.js | 0 .../app/tests/Marshalling/EnumTests.js | 0 .../tests/Marshalling/FunctionPointerTests.js | 8 - .../app/tests/Marshalling/MatrixTests.js | 0 .../app/tests/Marshalling/NSStringTests.js | 0 .../app/tests/Marshalling/ObjCTypesTests.js | 5 +- .../app/tests/Marshalling/PointerTests.js | 0 .../tests/Marshalling/Primitives/Derived.js | 0 .../tests/Marshalling/Primitives/Function.js | 0 .../tests/Marshalling/Primitives/Instance.js | 0 .../tests/Marshalling/Primitives/Static.js | 0 .../app/tests/Marshalling/ProtocolTests.js | 0 .../app/tests/Marshalling/RecordTests.js | 0 .../app/tests/Marshalling/ReferenceTests.js | 0 .../app/tests/Marshalling/TypesTests.js | 0 .../app/tests/Marshalling/VectorTests.js | 0 .../runner}/app/tests/MetadataTests.js | 0 .../runner}/app/tests/MethodCallsTests.js | 0 .../app/tests/Modules/WindowsEncoding.js | 0 .../runner}/app/tests/Modules/cjs-file.cjs | 0 .../runner}/app/tests/Modules/empty-file.js | 0 .../runner}/app/tests/Modules/index.js | 0 .../tests/Modules/strict-violation-default.js | 0 .../Modules/strict-violation-use-strict.js | 0 .../runner}/app/tests/ObjCConstructors.js | 0 .../runtime/runner}/app/tests/Promises.js | 0 .../app/tests/RuntimeImplementedAPIs.js | 0 .../runtime/runner}/app/tests/Timers.js | 14 +- .../runtime/runner}/app/tests/URL.js | 0 .../runtime/runner}/app/tests/URLPattern.js | 0 .../runner}/app/tests/URLSearchParams.js | 1 - .../runtime/runner}/app/tests/VMTests.js | 0 .../runner}/app/tests/VersionDiffTests.js | 0 .../runner}/app/tests/WebNodeBuiltins.js | 0 .../runtime/runner}/app/tests/index.js | 46 +- .../runtime/runner}/app/tests/macos.js | 0 .../runtime/runner}/app/tests/package.json | 0 .../runner}/app/tests/sdks/MusicKit.js | 0 .../runner}/app/tests/shared/.gitattributes | 0 .../shared/Import/ImportCommonJS/file.js | 0 .../shared/Import/ImportCommonJS/index.js | 0 .../tests/shared/Import/ImportJSON/data.json | 0 .../tests/shared/Import/ImportJSON/index.js | 0 .../runner}/app/tests/shared/Import/index.js | 0 .../runner}/app/tests/shared/README.md | 0 .../shared/Require/AbsolutePath/dependency.js | 0 .../shared/Require/AbsolutePath/index.js | 0 .../shared/Require/CaseSensitive/MyModule.js | 0 .../shared/Require/CaseSensitive/index.js | 0 .../Require/CaseSensitive/mymodule/index.js | 0 .../ChangingRequireObject/dependency.js | 0 .../Require/ChangingRequireObject/index.js | 0 .../CircularIndexRequire/dependency1.js | 0 .../CircularIndexRequire/dependency2.js | 0 .../Require/CircularIndexRequire/index.js | 0 .../Require/CircularRequire/dependency1.js | 0 .../Require/CircularRequire/dependency2.js | 0 .../Require/CircularRequire/dependency3.js | 0 .../shared/Require/CircularRequire/index.js | 0 .../CircularRequireWithExports/dependency1.js | 0 .../CircularRequireWithExports/dependency2.js | 0 .../CircularRequireWithExports/dependency3.js | 0 .../CircularRequireWithExports/index.js | 0 .../Require/DirectoryWithIndexJson/index.js | 0 .../DirectoryWithIndexJson/module/index.json | 0 .../dep1/dependency1.js | 0 .../dep2/dep2-inner/index.js | 0 .../DirnameAndFilenameParameters/index.js | 0 .../Require/ExportsBubbling/dependency1.js | 0 .../Require/ExportsBubbling/dependency2.js | 0 .../Require/ExportsBubbling/dependency3.js | 0 .../Require/ExportsBubbling/dependency4.js | 0 .../Require/ExportsBubbling/dependency5.js | 0 .../shared/Require/ExportsBubbling/index.js | 0 .../FileAndDirectoryWithSameName/index.js | 0 .../FileAndDirectoryWithSameName/module.js | 0 .../module/submodule.js | 0 .../FileEndingWithCommentedLine/index.js | 0 .../shared/Require/FileWithDots/file.name.js | 0 .../shared/Require/FileWithDots/index.js | 0 .../FiveLevelsOfRequire/dependency1.js | 0 .../FiveLevelsOfRequire/dependency2.js | 0 .../FiveLevelsOfRequire/dependency3.js | 0 .../FiveLevelsOfRequire/dependency4.js | 0 .../FiveLevelsOfRequire/dependency5.js | 0 .../Require/FiveLevelsOfRequire/index.js | 0 .../shared/Require/GlobalIsDefined/module.js | 0 .../shared/Require/GlobalRequire/index.js | 0 .../shared/Require/ModuleErrorCache/index.js | 0 .../Require/ModuleErrorCache/maybeThrow.js | 0 .../Require/ModuleRequireFunction/module1.js | 0 .../Require/ModuleRequireFunction/module2.js | 0 .../Require/ModuleVariable/dependency1.js | 0 .../Require/ModuleVariable/dependency2.js | 0 .../Require/ModuleVariable/dependency3.js | 0 .../Require/ModuleVariable/dependency4.js | 0 .../Require/ModuleVariable/dependency5.js | 0 .../shared/Require/ModuleVariable/index.js | 0 .../shared/Require/ModuleWith.js/index.js | 0 .../Require/ModuleWithNullChar/index.js | Bin .../Require/MultipleRequireOfAFile/index.js | 0 .../Require/MultipleRequireOfAFile/module.js | 0 .../Require/NestedGlobalObject/dependency1.js | 0 .../Require/NestedGlobalObject/dependency2.js | 0 .../Require/NestedGlobalObject/dependency3.js | 0 .../Require/NestedGlobalObject/dependency4.js | 0 .../Require/NestedGlobalObject/dependency5.js | 0 .../Require/NestedGlobalObject/index.js | 0 .../Require/NotExistingFileRequire/index.js | 0 .../shared/Require/PackageJsonApp/index.js | 0 .../shared/Require/PackageJsonApp/io/io.js | 0 .../Require/PackageJsonApp/io/package.json | 0 .../Require/PackageJsonAppNoMain/index.js | 0 .../Require/PackageJsonAppNoMain/io/index.js | 0 .../PackageJsonAppNoMain/io/package.json | 0 .../PackageJsonAppWithoutExtension/index.js | 0 .../PackageJsonAppWithoutExtension/io/io.js | 0 .../io/package.json | 0 .../PackageJsonMainPointsToDir/package.json | 0 .../subdirectory/index.js | 0 .../Require/PackageJsonSyntaxError/index.js | 0 .../PackageJsonSyntaxError/io/index.js | 0 .../PackageJsonSyntaxError/io/package.json | 0 .../shared/Require/PackageJsonTns/index.js | 0 .../Require/RequireExtensions/dependency1.js | 0 .../shared/Require/RequireExtensions/index.js | 0 .../Require/RequireJsonCorruptFile/index.js | 0 .../Require/RequireJsonCorruptFile/test.json | 0 .../RequireJsonCorruptFile1/badJSON.json | 0 .../Require/RequireJsonCorruptFile1/index.js | 0 .../shared/Require/RequireJsonFile/index.js | 0 .../shared/Require/RequireJsonFile/test.json | 0 .../Require/RequireModuleFolder/index.js | 0 .../RequireModuleFolderConflict/dependency.js | 0 .../RequireModuleFolderConflict/index.js | 0 .../Require/RequirePriority/dependency1.js | 0 .../Require/RequirePriority/dependency2.js | 0 .../RequirePriority/dependency3/index.js | 0 .../Require/RequirePriority/dependency4.js | 0 .../RequirePriority/dependency5/index.js | 0 .../shared/Require/RequirePriority/index.js | 0 .../Require/RequireWithTildeSyntax/module.js | 0 .../Require/ResolveCanonicalPath/index.js | 0 .../Require/ResolveCanonicalPath/package.json | 0 .../Require/ResolveCanonicalPath/second.js | 0 .../RuntimeErrorInModule/dependency.js | 0 .../Require/RuntimeErrorInModule/index.js | 0 .../Require/SimpleGlobalObject/dependency.js | 0 .../Require/SimpleGlobalObject/index.js | 0 .../Require/SimpleRequire/dependency.js | 0 .../shared/Require/SimpleRequire/index.js | 0 .../SimpleRequireWithExports/dependency.js | 0 .../Require/SimpleRequireWithExports/index.js | 0 .../Require/SyntaxErrorInModule/dependency.js | 0 .../Require/SyntaxErrorInModule/index.js | 0 .../Require/TwoLevelsOfRequire/dependency1.js | 0 .../Require/TwoLevelsOfRequire/dependency2.js | 0 .../Require/TwoLevelsOfRequire/index.js | 0 .../dependency1.js | 0 .../dependency2.js | 0 .../TwoLevelsOfRequireWithExports/index.js | 0 .../runner}/app/tests/shared/Require/index.js | 0 .../runner}/app/tests/shared/RuntimeTests.js | 0 .../runner}/app/tests/shared/WeakRef.js | 0 .../app/tests/shared/Workers/EvalWorker.js | 0 .../shared/Workers/WorkerInvalidSyntax.js | 0 .../shared/Workers/WorkerStressJSTest.js | 0 .../runner}/app/tests/shared/Workers/index.js | 0 .../runtime/runner}/app/tests/shared/index.js | 0 .../runner}/app/tests/shared/package.json | 0 .../app/tns_modules/core-module-dir/index.js | 0 .../runner}/app/tns_modules/core-module.js | 0 .../app/tns_modules/dummy-package/index.js | 0 .../tns_modules/dummy-package/package.json | 0 .../tns-core-modules/shared/.gitattributes | 0 .../tns-core-modules/shared/README.md | 0 .../shared/Require/PackageJsonTns/io/io.js | 0 .../Require/PackageJsonTns/io/package.json | 0 .../Require/RequireModuleFolder/dependency.js | 0 .../RequireModuleFolderConflict/dependency.js | 0 .../Require/RequirePriority/dependency1.js | 0 .../RequirePriority/dependency2/index.js | 0 .../RequirePriority/dependency3/index.js | 0 .../Require/RequirePriority/dependency4.js | 0 .../RequirePriority/dependency5/module.js | 0 .../RequirePriority/dependency5/package.json | 0 test_extend.js | 34 - testesm.sh | 2 - update_version.sh | 11 - v8-version.txt | 1 - 545 files changed, 3630 insertions(+), 143371 deletions(-) delete mode 100644 .travis.yml delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/Info.plist delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSData+Async.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSString+Async.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSLabel.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSProcess.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSWidgets.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIView+PassThroughParent.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Info.plist delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Modules/module.modulemap delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h delete mode 100755 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/TNSWidgets delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Info.plist delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Modules/module.modulemap delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h delete mode 100755 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/TNSWidgets delete mode 100644 AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/_CodeSignature/CodeResources delete mode 100644 AppWithModules/Info.plist delete mode 100644 AppWithModules/Source Files/main.m delete mode 100644 AppWithModules/app/bundle.js delete mode 100644 AppWithModules/app/package.json delete mode 100644 AppWithModules/app/runtime.js delete mode 100644 AppWithModules/app/tns_modules/tns-core-modules/inspector_modules.js delete mode 100644 AppWithModules/app/vendor.js create mode 100644 NativeScript/libffi/xros-arm64/include/ffi.h create mode 100644 NativeScript/libffi/xros-arm64/include/ffitarget.h create mode 100644 NativeScript/libffi/xros-arm64/libffi.a create mode 100644 NativeScript/libffi/xrsimulator-arm64/include/ffi.h create mode 100644 NativeScript/libffi/xrsimulator-arm64/include/ffitarget.h create mode 100644 NativeScript/libffi/xrsimulator-arm64/libffi.a delete mode 100644 TestRunner/Default-568h@2x.png delete mode 100644 TestRunner/app/tests/Infrastructure/simulator.js delete mode 100644 TestRunnerTests/Embassy/Atomic.swift delete mode 100644 TestRunnerTests/Embassy/DefaultHTTPServer.swift delete mode 100644 TestRunnerTests/Embassy/DefaultLogFormatter.swift delete mode 100644 TestRunnerTests/Embassy/DefaultLogger.swift delete mode 100644 TestRunnerTests/Embassy/Embassy.h delete mode 100644 TestRunnerTests/Embassy/Errors.swift delete mode 100644 TestRunnerTests/Embassy/EventLoop.swift delete mode 100644 TestRunnerTests/Embassy/FileLogHandler.swift delete mode 100644 TestRunnerTests/Embassy/HTTPConnection.swift delete mode 100644 TestRunnerTests/Embassy/HTTPHeaderParser.swift delete mode 100644 TestRunnerTests/Embassy/HTTPRequest.swift delete mode 100644 TestRunnerTests/Embassy/HTTPServer.swift delete mode 100644 TestRunnerTests/Embassy/HeapSort.swift delete mode 100644 TestRunnerTests/Embassy/IOUtils.swift delete mode 100644 TestRunnerTests/Embassy/KqueueSelector.swift delete mode 100644 TestRunnerTests/Embassy/LogFormatter.swift delete mode 100644 TestRunnerTests/Embassy/LogHandler.swift delete mode 100644 TestRunnerTests/Embassy/Logger.swift delete mode 100644 TestRunnerTests/Embassy/MultiDictionary.swift delete mode 100644 TestRunnerTests/Embassy/PrintLogHandler.swift delete mode 100644 TestRunnerTests/Embassy/PropagateLogHandler.swift delete mode 100644 TestRunnerTests/Embassy/SWSGI.swift delete mode 100644 TestRunnerTests/Embassy/SWSGIUtils.swift delete mode 100644 TestRunnerTests/Embassy/SelectSelector.swift delete mode 100644 TestRunnerTests/Embassy/Selector.swift delete mode 100644 TestRunnerTests/Embassy/SelectorEventLoop.swift delete mode 100644 TestRunnerTests/Embassy/SystemLibrary.swift delete mode 100644 TestRunnerTests/Embassy/TCPSocket.swift delete mode 100644 TestRunnerTests/Embassy/TransformLogHandler.swift delete mode 100644 TestRunnerTests/Embassy/Transport.swift delete mode 100644 TestRunnerTests/Info.plist delete mode 100644 TestRunnerTests/TestRunnerTests.m delete mode 100644 TestRunnerTests/TestRunnerTests.swift delete mode 100644 TestRunnerUITests/TestRunnerUITests.m delete mode 100644 TestRunnerUITests/TestRunnerUITestsLaunchTests.m delete mode 100755 build_all_macos.sh delete mode 100755 build_all_react_native.sh delete mode 100755 build_all_vision.sh delete mode 100755 build_npm_ios.sh delete mode 100755 build_npm_macos.sh delete mode 100755 build_npm_node_api.sh delete mode 100755 build_npm_vision.sh rename packages/{objc => ios-node-api}/LICENSE (100%) create mode 100644 packages/ios-node-api/README.md rename packages/{ios => ios-node-api}/deno.json (100%) rename packages/{ios => ios-node-api}/index.d.ts (100%) rename packages/{ios => ios-node-api}/index.js (100%) rename packages/{ios => ios-node-api}/mod.ts (100%) create mode 100644 packages/ios-node-api/package.json rename packages/{macos => macos-node-api}/.gitignore (100%) create mode 100644 packages/macos-node-api/LICENSE create mode 100644 packages/macos-node-api/README.md rename packages/{macos => macos-node-api}/deno.json (100%) rename packages/{macos => macos-node-api}/index.cjs (100%) rename packages/{macos => macos-node-api}/index.d.ts (100%) rename packages/{macos => macos-node-api}/index.mjs (100%) rename packages/{macos => macos-node-api}/mod.ts (100%) create mode 100644 packages/macos-node-api/package.json delete mode 120000 packages/macos/build/RelWithDebInfo/NativeScript.apple.node/macos-arm64/NativeScript.framework/Versions/A create mode 100644 packages/objc-node-api/LICENSE rename packages/{objc => objc-node-api}/README.md (100%) rename packages/{objc => objc-node-api}/index.d.ts (100%) rename packages/{objc => objc-node-api}/index.js (100%) rename packages/{objc => objc-node-api}/inline_functions.d.ts (100%) rename packages/{objc => objc-node-api}/package.json (95%) create mode 100644 packages/visionos/LICENSE create mode 100644 packages/visionos/README.md create mode 100644 packages/visionos/package.json delete mode 100644 prepare-target.js delete mode 100644 run-tests.js rename build_all_ios.sh => scripts/build_all_ios.sh (78%) create mode 100755 scripts/build_all_macos.sh rename build_all_node_api.sh => scripts/build_all_node_api.sh (86%) create mode 100755 scripts/build_all_react_native.sh create mode 100755 scripts/build_all_vision.sh rename build_libffi.sh => scripts/build_libffi.sh (99%) rename build_metadata_generator.sh => scripts/build_metadata_generator.sh (100%) rename build_nativescript.sh => scripts/build_nativescript.sh (84%) create mode 100755 scripts/build_npm_ios.sh create mode 100755 scripts/build_npm_macos.sh create mode 100755 scripts/build_npm_node_api.sh create mode 100755 scripts/build_npm_vision.sh rename build_testrunner.sh => scripts/build_testrunner.sh (95%) rename build_tklivesync.sh => scripts/build_tklivesync.sh (84%) rename build_utils.sh => scripts/build_utils.sh (87%) rename download_hermes.sh => scripts/download_hermes.sh (100%) rename download_llvm.sh => scripts/download_llvm.sh (100%) rename download_v8.sh => scripts/download_v8.sh (100%) rename prepare_dSYMs.sh => scripts/prepare_dSYMs.sh (77%) create mode 100755 scripts/testesm.sh create mode 100755 scripts/update_version.sh rename {project-template-ios => templates/ios}/__PROJECT_NAME__.xcodeproj/project.pbxproj (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__.xcodeproj/xcshareddata/xcschemes/__PROJECT_NAME__.xcscheme (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/__PROJECT_NAME__-Prefix.pch (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/__PROJECT_NAME__.entitlements (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/build-debug.xcconfig (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/build-release.xcconfig (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/build.xcconfig (100%) rename {project-template-ios => templates/ios}/__PROJECT_NAME__/en.lproj/InfoPlist.strings (100%) rename {project-template-ios => templates/ios}/internal/NativeScriptStart.h (100%) rename {project-template-ios => templates/ios}/internal/NativeScriptStart.m (100%) rename {project-template-ios => templates/ios}/internal/README.md (100%) rename {project-template-ios => templates/ios}/internal/Swift-ObjC-Bridging-Header.h (100%) rename {project-template-ios => templates/ios}/internal/macros.h (100%) rename {project-template-ios => templates/ios}/internal/main.m (100%) rename {project-template-ios => templates/ios}/internal/nativescript-build.xcconfig (100%) rename {project-template-ios => templates/ios}/internal/nativescript-post-build (100%) rename {project-template-ios => templates/ios}/internal/nativescript-pre-build (100%) rename {project-template-ios => templates/ios}/internal/nativescript-pre-link (100%) rename {project-template-ios => templates/ios}/internal/nsld.sh (100%) rename {project-template-ios => templates/ios}/internal/strip-dynamic-framework-architectures.sh (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__.xcodeproj/project.pbxproj (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__.xcodeproj/project.xcworkspace/contents.xcworkspacedata (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__.xcodeproj/xcshareddata/xcschemes/__PROJECT_NAME__.xcscheme (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/__PROJECT_NAME__-Prefix.pch (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/__PROJECT_NAME__.entitlements (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/build-debug.xcconfig (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/build-release.xcconfig (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/build.xcconfig (100%) rename {project-template-macos => templates/macos}/__PROJECT_NAME__/en.lproj/InfoPlist.strings (100%) rename {project-template-macos => templates/macos}/internal/NativeScriptStart.h (100%) rename {project-template-macos => templates/macos}/internal/NativeScriptStart.m (100%) rename {project-template-macos => templates/macos}/internal/README.md (100%) rename {project-template-macos => templates/macos}/internal/Swift-ObjC-Bridging-Header.h (100%) rename {project-template-macos => templates/macos}/internal/macros.h (100%) rename {project-template-macos => templates/macos}/internal/main.m (100%) rename {project-template-macos => templates/macos}/internal/nativescript-build.xcconfig (100%) rename {project-template-macos => templates/macos}/internal/nativescript-post-build (100%) rename {project-template-macos => templates/macos}/internal/nativescript-pre-build (100%) rename {project-template-macos => templates/macos}/internal/nativescript-pre-link (100%) rename {project-template-macos => templates/macos}/internal/nsld.sh (100%) rename {project-template-macos => templates/macos}/internal/strip-dynamic-framework-architectures.sh (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__.xcodeproj/project.pbxproj (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__.xcodeproj/xcshareddata/xcschemes/__PROJECT_NAME__.xcscheme (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/__PROJECT_NAME__-Prefix.pch (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/__PROJECT_NAME__.entitlements (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/build-debug.xcconfig (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/build-release.xcconfig (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/build.xcconfig (100%) rename {project-template-vision => templates/visionos}/__PROJECT_NAME__/en.lproj/InfoPlist.strings (100%) rename {project-template-vision => templates/visionos}/internal/NativeScriptStart.h (100%) rename {project-template-vision => templates/visionos}/internal/NativeScriptStart.m (100%) rename {project-template-vision => templates/visionos}/internal/README.md (100%) rename {project-template-vision => templates/visionos}/internal/Swift-ObjC-Bridging-Header.h (100%) rename {project-template-vision => templates/visionos}/internal/macros.h (100%) rename {project-template-vision => templates/visionos}/internal/nativescript-build.xcconfig (100%) rename {project-template-vision => templates/visionos}/internal/nativescript-post-build (100%) rename {project-template-vision => templates/visionos}/internal/nativescript-pre-build (100%) rename {project-template-vision => templates/visionos}/internal/nativescript-pre-link (100%) rename {project-template-vision => templates/visionos}/internal/nsld.sh (100%) rename {project-template-vision => templates/visionos}/internal/strip-dynamic-framework-architectures.sh (100%) rename {cli_tests => test/cli}/assets/icon.png (100%) rename {cli_tests => test/cli}/benchmark/foundation_calls.js (100%) rename {cli_tests => test/cli}/benchmark/run_foundation_bench.js (100%) rename {cli_tests => test/cli}/error.js (100%) rename {cli_tests => test/cli}/esm_a.mjs (100%) rename {cli_tests => test/cli}/esm_b.mjs (100%) rename {cli_tests => test/cli}/gc.js (100%) rename {cli_tests => test/cli}/gc2.js (100%) rename {cli_tests => test/cli}/index.js (100%) rename {cli_tests => test/cli}/main_worker.js (90%) rename {cli_tests => test/cli}/memory/_harness.js (100%) rename {cli_tests => test/cli}/memory/_plain_harness.js (100%) rename {cli_tests => test/cli}/memory/appkit_navigation_visual_demo.js (100%) rename {cli_tests => test/cli}/memory/run_memory_semantics_tests.js (100%) rename {cli_tests => test/cli}/memory/run_memory_tests.js (100%) rename {cli_tests => test/cli}/memory/run_memory_tests_all_engines.sh (70%) rename {cli_tests => test/cli}/memory/test_appkit_navigation_extreme.js (100%) rename {cli_tests => test/cli}/memory/test_appkit_navigation_throughput.js (100%) rename {cli_tests => test/cli}/memory/test_block_callback_finalization.js (100%) rename {cli_tests => test/cli}/memory/test_block_completion_safety.js (100%) rename {cli_tests => test/cli}/memory/test_block_lifecycle.js (100%) rename {cli_tests => test/cli}/memory/test_c_function_pointer_semantics.js (100%) rename {cli_tests => test/cli}/memory/test_dispatch_async_background.js (100%) rename {cli_tests => test/cli}/memory/test_js_heap_throughput.js (100%) rename {cli_tests => test/cli}/memory/test_mixed_stress.js (100%) rename {cli_tests => test/cli}/memory/test_objc_ownership_rules.js (100%) rename {cli_tests => test/cli}/memory/test_objc_wrapper_churn.js (100%) rename {cli_tests => test/cli}/memory/test_objc_wrapper_finalization.js (100%) rename {cli_tests => test/cli}/memory/test_plain_script_runloop_drain.js (100%) rename {cli_tests => test/cli}/memory/test_pointer_c_buffer_semantics.js (100%) rename {cli_tests => test/cli}/memory/test_reference_lifecycle.js (100%) rename {cli_tests => test/cli}/memory/test_runloop_pending_work.js (100%) rename {cli_tests => test/cli}/memory/test_weakref_finalization.js (100%) rename {cli_tests => test/cli}/memory/test_weakref_plain_script.js (100%) rename {cli_tests => test/cli}/module_a.js (100%) rename {cli_tests => test/cli}/node_api/.gitignore (100%) rename {cli_tests => test/cli}/node_api/addon.cpp (100%) rename {cli_tests => test/cli}/node_api/build_addon.sh (75%) rename {cli_tests => test/cli}/node_api/cleanup_teardown.js (100%) rename {cli_tests => test/cli}/node_api/reentry_tsfn.js (100%) rename {cli_tests => test/cli}/node_api/run_teardown_test.sh (84%) rename {cli_tests => test/cli}/threadsafe.js (100%) rename {cli_tests => test/cli}/view_controller_app.js (100%) rename {cli_tests => test/cli}/vm.js (100%) rename {cli_tests => test/cli}/worker.js (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSApi.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSApi.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSBridgedTypes.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSBridgedTypes.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSDeclarationConflicts.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSDeclarationConflicts.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSPseudoDataTypes.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSPseudoDataTypes.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSReturnsRetained.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSReturnsRetained.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSReturnsUnmanaged.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSReturnsUnmanaged.m (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSVersions.h (100%) rename {TestFixtures => test/runtime/fixtures}/Api/TNSVersions.m (100%) rename {TestFixtures => test/runtime/fixtures}/Functions/TNSFunctions.h (100%) rename {TestFixtures => test/runtime/fixtures}/Functions/TNSFunctions.m (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSClassWithPlaceholder.h (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSClassWithPlaceholder.m (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSConstructorResolution.h (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSConstructorResolution.m (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSInheritance.h (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSInheritance.m (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSMethodCalls.h (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSMethodCalls.m (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSSwiftLike.h (100%) rename {TestFixtures => test/runtime/fixtures}/Interfaces/TNSSwiftLike.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSAllocLog.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSAllocLog.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSFunctionPointers.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSFunctionPointers.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSObjCTypes.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSObjCTypes.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSPrimitivePointers.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSPrimitivePointers.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSPrimitives.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSPrimitives.m (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSRecords.h (100%) rename {TestFixtures => test/runtime/fixtures}/Marshalling/TNSRecords.m (100%) rename {TestFixtures => test/runtime/fixtures}/TNSTestCommon.h (100%) rename {TestFixtures => test/runtime/fixtures}/TNSTestCommon.m (100%) rename {TestFixtures => test/runtime/fixtures}/TNSTestNativeCallbacks.h (100%) rename {TestFixtures => test/runtime/fixtures}/TNSTestNativeCallbacks.m (100%) rename {TestFixtures => test/runtime/fixtures}/TestFixtures-Prefix.h (100%) rename {TestFixtures => test/runtime/fixtures}/TestFixtures.h (100%) rename {TestFixtures => test/runtime/fixtures}/exported-symbols.txt (100%) rename {TestFixtures => test/runtime/fixtures}/module.modulemap (100%) rename {TestRunner => test/runtime/runner}/Assets.xcassets/AccentColor.colorset/Contents.json (100%) rename {TestRunner => test/runtime/runner}/Assets.xcassets/AppIcon.appiconset/Contents.json (100%) rename {TestRunner => test/runtime/runner}/Assets.xcassets/Contents.json (100%) rename {AppWithModules => test/runtime/runner}/Default-568h@2x.png (100%) rename {TestRunner => test/runtime/runner}/Info.plist (100%) rename {TestRunner => test/runtime/runner}/Source Files/main.m (100%) rename {TestRunner => test/runtime/runner}/app/index.js (100%) rename {TestRunner => test/runtime/runner}/app/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/.gitignore (100%) rename {TestRunner => test/runtime/runner}/app/tests/ApiTests.js (93%) rename {TestRunner => test/runtime/runner}/app/tests/DeclarationConflicts.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/ExceptionHandlingTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/FunctionsTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/Jasmine/jasmine-2.0.1/boot.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/Jasmine/jasmine-2.0.1/jasmine.js (99%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/Jasmine/jasmine-reporters/junit_reporter.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/Jasmine/jasmine-reporters/terminal_reporter.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/Jasmine/jasmine.d.ts (100%) create mode 100644 test/runtime/runner/app/tests/Infrastructure/simulator.js rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/timers.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Infrastructure/utf8.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Inheritance/InheritanceTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Inheritance/ProtocolImplementationTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Inheritance/TypeScriptTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Inheritance/TypeScriptTests.ts (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/ConstantsTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/EnumTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/FunctionPointerTests.js (78%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/MatrixTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/NSStringTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/ObjCTypesTests.js (98%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/PointerTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/Primitives/Derived.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/Primitives/Function.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/Primitives/Instance.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/Primitives/Static.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/ProtocolTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/RecordTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/ReferenceTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/TypesTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Marshalling/VectorTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/MetadataTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/MethodCallsTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/WindowsEncoding.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/cjs-file.cjs (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/empty-file.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/strict-violation-default.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Modules/strict-violation-use-strict.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/ObjCConstructors.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Promises.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/RuntimeImplementedAPIs.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/Timers.js (92%) rename {TestRunner => test/runtime/runner}/app/tests/URL.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/URLPattern.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/URLSearchParams.js (98%) rename {TestRunner => test/runtime/runner}/app/tests/VMTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/VersionDiffTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/WebNodeBuiltins.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/index.js (85%) rename {TestRunner => test/runtime/runner}/app/tests/macos.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/sdks/MusicKit.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/.gitattributes (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Import/ImportCommonJS/file.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Import/ImportCommonJS/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Import/ImportJSON/data.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Import/ImportJSON/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Import/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/README.md (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/AbsolutePath/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/AbsolutePath/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CaseSensitive/MyModule.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CaseSensitive/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CaseSensitive/mymodule/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ChangingRequireObject/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ChangingRequireObject/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularIndexRequire/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularIndexRequire/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularIndexRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequire/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequire/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequire/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequireWithExports/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequireWithExports/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequireWithExports/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/CircularRequireWithExports/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/DirectoryWithIndexJson/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/DirectoryWithIndexJson/module/index.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/DirnameAndFilenameParameters/dep1/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/DirnameAndFilenameParameters/dep2/dep2-inner/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/DirnameAndFilenameParameters/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/dependency5.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ExportsBubbling/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileAndDirectoryWithSameName/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileAndDirectoryWithSameName/module.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileAndDirectoryWithSameName/module/submodule.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileEndingWithCommentedLine/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileWithDots/file.name.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FileWithDots/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/dependency5.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/FiveLevelsOfRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/GlobalIsDefined/module.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/GlobalRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleErrorCache/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleErrorCache/maybeThrow.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleRequireFunction/module1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleRequireFunction/module2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/dependency5.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleVariable/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleWith.js/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ModuleWithNullChar/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/MultipleRequireOfAFile/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/MultipleRequireOfAFile/module.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/dependency3.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/dependency5.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NestedGlobalObject/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/NotExistingFileRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonApp/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonApp/io/io.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonApp/io/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppNoMain/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppNoMain/io/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppNoMain/io/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppWithoutExtension/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppWithoutExtension/io/io.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonAppWithoutExtension/io/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonMainPointsToDir/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonMainPointsToDir/subdirectory/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonSyntaxError/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonSyntaxError/io/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonSyntaxError/io/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/PackageJsonTns/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireExtensions/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireExtensions/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonCorruptFile/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonCorruptFile/test.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonCorruptFile1/badJSON.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonCorruptFile1/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonFile/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireJsonFile/test.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireModuleFolder/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireModuleFolderConflict/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireModuleFolderConflict/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/dependency3/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/dependency5/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequirePriority/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RequireWithTildeSyntax/module.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ResolveCanonicalPath/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ResolveCanonicalPath/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/ResolveCanonicalPath/second.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RuntimeErrorInModule/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/RuntimeErrorInModule/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleGlobalObject/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleGlobalObject/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleRequire/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleRequireWithExports/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SimpleRequireWithExports/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SyntaxErrorInModule/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/SyntaxErrorInModule/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequire/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequire/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequire/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequireWithExports/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequireWithExports/dependency2.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/TwoLevelsOfRequireWithExports/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Require/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/RuntimeTests.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/WeakRef.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Workers/EvalWorker.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Workers/WorkerInvalidSyntax.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Workers/WorkerStressJSTest.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/Workers/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tests/shared/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/core-module-dir/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/core-module.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/dummy-package/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/dummy-package/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/.gitattributes (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/README.md (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/PackageJsonTns/io/io.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/PackageJsonTns/io/package.json (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequireModuleFolder/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequireModuleFolderConflict/dependency.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency1.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency2/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency3/index.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency4.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency5/module.js (100%) rename {TestRunner => test/runtime/runner}/app/tns_modules/tns-core-modules/shared/Require/RequirePriority/dependency5/package.json (100%) delete mode 100644 test_extend.js delete mode 100755 testesm.sh delete mode 100755 update_version.sh delete mode 100644 v8-version.txt diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5bd84ec6..ce8f3cc0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,7 @@ jobs: run: npm install - name: Download V8 - run: ./download_v8.sh + run: ./scripts/download_v8.sh - name: Install libffi build tools run: brew install autoconf automake libtool texinfo diff --git a/.github/workflows/npm_napi_release.yml b/.github/workflows/npm_napi_release.yml index d8dd793b..daa75ec0 100644 --- a/.github/workflows/npm_napi_release.yml +++ b/.github/workflows/npm_napi_release.yml @@ -58,45 +58,45 @@ jobs: if: ${{ !contains(github.ref, 'refs/tags/') }} run: | # Bump @nativescript/ios-node-api - NPM_VERSION_IOS=$(node ./scripts/get-next-version.js ios) + NPM_VERSION_IOS=$(node ./scripts/get-next-version.js ios-node-api) echo NPM_VERSION_IOS=$NPM_VERSION_IOS >> $GITHUB_ENV - cd packages/ios + cd packages/ios-node-api npm version $NPM_VERSION_IOS --no-git-tag-version cd - # Bump @nativescript/macos-node-api - NPM_VERSION_MACOS=$(node ./scripts/get-next-version.js macos) + NPM_VERSION_MACOS=$(node ./scripts/get-next-version.js macos-node-api) echo NPM_VERSION_MACOS=$NPM_VERSION_MACOS >> $GITHUB_ENV - cd packages/macos + cd packages/macos-node-api npm version $NPM_VERSION_MACOS --no-git-tag-version cd - - name: Output NPM Versions and tags id: npm_version_output run: | - NPM_TAG_IOS=$(node ./scripts/get-npm-tag.js ios) - NPM_TAG_MACOS=$(node ./scripts/get-npm-tag.js macos) + NPM_TAG_IOS=$(node ./scripts/get-npm-tag.js ios-node-api) + NPM_TAG_MACOS=$(node ./scripts/get-npm-tag.js macos-node-api) echo NPM_VERSION_IOS=$NPM_VERSION_IOS >> $GITHUB_OUTPUT echo NPM_VERSION_MACOS=$NPM_VERSION_MACOS >> $GITHUB_OUTPUT echo NPM_TAG_IOS=$NPM_TAG_IOS >> $GITHUB_OUTPUT echo NPM_TAG_MACOS=$NPM_TAG_MACOS >> $GITHUB_OUTPUT - name: Build - run: ./build_all_react_native.sh + run: ./scripts/build_all_react_native.sh - name: Pack @nativescript/ios-node-api - working-directory: packages/ios - run: npm pack + working-directory: packages/ios-node-api + run: npm pack --pack-destination dist - name: Pack @nativescript/macos-node-api - working-directory: packages/macos - run: npm pack + working-directory: packages/macos-node-api + run: npm pack --pack-destination dist - name: Upload npm package artifact for @nativescript/ios-node-api uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 with: name: nativescript-ios-node-api - path: packages/ios/nativescript-ios-node-api-${{steps.npm_version_output.outputs.NPM_VERSION_IOS}}.tgz + path: packages/ios-node-api/dist/nativescript-ios-node-api-${{steps.npm_version_output.outputs.NPM_VERSION_IOS}}.tgz - name: Upload npm package artifact for @nativescript/macos-node-api uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 with: name: nativescript-macos-node-api - path: packages/macos/nativescript-macos-node-api-${{steps.npm_version_output.outputs.NPM_VERSION_MACOS}}.tgz + path: packages/macos-node-api/dist/nativescript-macos-node-api-${{steps.npm_version_output.outputs.NPM_VERSION_MACOS}}.tgz publish: runs-on: ubuntu-latest environment: npm-publish @@ -122,11 +122,11 @@ jobs: - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: nativescript-ios-node-api - path: packages/ios + path: packages/ios-node-api/dist - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: nativescript-macos-node-api - path: packages/macos + path: packages/macos-node-api/dist - name: Update npm (required for OIDC trusted publishing) run: | npm install -g npm@^11.6.2 @@ -139,7 +139,7 @@ jobs: if [ -n "${NPM_CONFIG_USERCONFIG:-}" ]; then rm -f "$NPM_CONFIG_USERCONFIG" fi - npm publish packages/ios/nativescript-ios-node-api-${{env.NPM_VERSION_IOS}}.tgz --tag $NPM_TAG_IOS --access public --provenance + npm publish packages/ios-node-api/dist/nativescript-ios-node-api-${{env.NPM_VERSION_IOS}}.tgz --tag $NPM_TAG_IOS --access public --provenance env: NODE_AUTH_TOKEN: "" - name: Publish @nativescript/macos-node-api package (OIDC trusted publishing) @@ -150,21 +150,21 @@ jobs: if [ -n "${NPM_CONFIG_USERCONFIG:-}" ]; then rm -f "$NPM_CONFIG_USERCONFIG" fi - npm publish packages/macos/nativescript-macos-node-api-${{env.NPM_VERSION_MACOS}}.tgz --tag $NPM_TAG_MACOS --access public --provenance + npm publish packages/macos-node-api/dist/nativescript-macos-node-api-${{env.NPM_VERSION_MACOS}}.tgz --tag $NPM_TAG_MACOS --access public --provenance env: NODE_AUTH_TOKEN: "" - name: Publish @nativescript/ios-node-api package (granular token) if: ${{ vars.USE_NPM_TOKEN == 'true' }} run: | echo "Publishing @nativescript/ios-node-api@$NPM_VERSION to NPM with tag $NPM_TAG_IOS via granular token..." - npm publish packages/ios/nativescript-ios-node-api-${{env.NPM_VERSION_IOS}}.tgz --tag $NPM_TAG_IOS --access public --provenance + npm publish packages/ios-node-api/dist/nativescript-ios-node-api-${{env.NPM_VERSION_IOS}}.tgz --tag $NPM_TAG_IOS --access public --provenance env: NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} - name: Publish @nativescript/macos-node-api package (granular token) if: ${{ vars.USE_NPM_TOKEN == 'true' }} run: | echo "Publishing @nativescript/macos-node-api@$NPM_VERSION to NPM with tag $NPM_TAG_MACOS via granular token..." - npm publish packages/macos/nativescript-macos-node-api-${{env.NPM_VERSION_MACOS}}.tgz --tag $NPM_TAG_MACOS --access public --provenance + npm publish packages/macos-node-api/dist/nativescript-macos-node-api-${{env.NPM_VERSION_MACOS}}.tgz --tag $NPM_TAG_MACOS --access public --provenance env: NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} github-release: @@ -194,20 +194,20 @@ jobs: - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: nativescript-ios-node-api - path: packages/ios + path: packages/ios-node-api/dist - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: nativescript-macos-node-api - path: packages/macos + path: packages/macos-node-api/dist - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: nativescript-macos-node-api - path: packages/macos + path: packages/macos-node-api/dist - name: Partial Changelog run: npx conventional-changelog -p angular -r2 > body.md - uses: ncipollo/release-action@b7eabc95ff50cbeeedec83973935c8f306dfcd0b # v1.20.0 with: - artifacts: "packages/macos/nativescript-macos-node-api-*.tgz,packages/ios/nativescript-ios-node-api-*.tgz" + artifacts: "packages/macos-node-api/dist/nativescript-macos-node-api-*.tgz,packages/ios-node-api/dist/nativescript-ios-node-api-*.tgz" bodyFile: "body.md" prerelease: ${{needs.build.outputs.npm_tag_ios != 'latest' && needs.build.outputs.npm_tag_macos != 'latest'}} allowUpdates: true diff --git a/.github/workflows/npm_release.yml b/.github/workflows/npm_release.yml index 662b212e..373f0a90 100644 --- a/.github/workflows/npm_release.yml +++ b/.github/workflows/npm_release.yml @@ -55,18 +55,19 @@ jobs: fi - name: Get Current Version run: | - NPM_VERSION=$(node -e "console.log(require('./package.json').version);") + NPM_VERSION=$(node -e "console.log(require('./packages/ios/package.json').version);") echo NPM_VERSION=$NPM_VERSION >> $GITHUB_ENV - name: Bump version for dev release if: ${{ !contains(github.ref, 'refs/tags/') }} run: | - NPM_VERSION=$(node ./scripts/get-next-version.js root) + NPM_VERSION=$(node ./scripts/get-next-version.js ios) echo NPM_VERSION=$NPM_VERSION >> $GITHUB_ENV + cd packages/ios npm version $NPM_VERSION --no-git-tag-version - name: Output NPM Version and tag id: npm_version_output run: | - NPM_TAG=$(node ./scripts/get-npm-tag.js root) + NPM_TAG=$(node ./scripts/get-npm-tag.js ios) echo NPM_VERSION=$NPM_VERSION >> $GITHUB_OUTPUT echo NPM_TAG=$NPM_TAG >> $GITHUB_OUTPUT - name: Build @@ -75,7 +76,7 @@ jobs: uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 with: name: npm-package - path: dist/nativescript-ios-${{steps.npm_version_output.outputs.NPM_VERSION}}.tgz + path: packages/ios/dist/nativescript-ios-${{steps.npm_version_output.outputs.NPM_VERSION}}.tgz - name: Upload dSYMs artifact uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 with: @@ -171,7 +172,7 @@ jobs: - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 with: name: npm-package - path: dist + path: packages/ios/dist - name: Update npm (required for OIDC trusted publishing) run: | npm install -g npm@^11.5.1 @@ -184,7 +185,7 @@ jobs: if [ -n "${NPM_CONFIG_USERCONFIG:-}" ]; then rm -f "$NPM_CONFIG_USERCONFIG" fi - npm publish ./dist/nativescript-ios-${{env.NPM_VERSION}}.tgz --tag $NPM_TAG --access public --provenance + npm publish ./packages/ios/dist/nativescript-ios-${{env.NPM_VERSION}}.tgz --tag $NPM_TAG --access public --provenance env: NODE_AUTH_TOKEN: "" @@ -192,7 +193,7 @@ jobs: if: ${{ vars.USE_NPM_TOKEN == 'true' }} run: | echo "Publishing @nativescript/ios@$NPM_VERSION to NPM with tag $NPM_TAG via granular token..." - npm publish ./dist/nativescript-ios-${{env.NPM_VERSION}}.tgz --tag $NPM_TAG --access public --provenance + npm publish ./packages/ios/dist/nativescript-ios-${{env.NPM_VERSION}}.tgz --tag $NPM_TAG --access public --provenance env: NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} github-release: @@ -234,7 +235,7 @@ jobs: run: npx conventional-changelog -p angular -r2 > body.md - uses: ncipollo/release-action@b7eabc95ff50cbeeedec83973935c8f306dfcd0b # v1.20.0 with: - artifacts: "dist/nativescript-ios-*.tgz,dist/dSYMs/*.zip" + artifacts: "packages/ios/dist/nativescript-ios-*.tgz,dist/dSYMs/*.zip" bodyFile: "body.md" prerelease: ${{needs.build.outputs.npm_tag != 'latest'}} allowUpdates: true diff --git a/.gitignore b/.gitignore index 25430b89..dc351670 100644 --- a/.gitignore +++ b/.gitignore @@ -52,10 +52,10 @@ v8_build .cipd/ # project template -/project-template-ios/.build_env_vars.sh -/project-template-ios/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/ -/project-template-vision/.build_env_vars.sh -/project-template-vision/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +/templates/ios/.build_env_vars.sh +/templates/ios/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/ +/templates/visionos/.build_env_vars.sh +/templates/visionos/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist .cache/ diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 9c2373c8..00000000 --- a/.travis.yml +++ /dev/null @@ -1,21 +0,0 @@ -os: osx -osx_image: xcode13.2 -language: objective-c -git: - submodules: true - depth: 1 - -before_install: - - cmake --version - - make --version - - brew install chargepoint/xcparse/xcparse - - npm install junit-cli-report-viewer - -script: - - set -o pipefail && xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $HOME/test_results -resultBundleVersion 3 -destination platform\=iOS\ Simulator,OS\=15.2,name\=iPhone\ 11\ Pro\ Max build test | xcpretty - - set -e && xcparse attachments $HOME/test_results.xcresult $HOME - - set -e && find $HOME -name "*junit*.xml" -maxdepth 1 -exec npx junit-cli-report-viewer {} \; - -#xcode_project: v8ios.xcodeproj -#xcode_scheme: TestRunner -#xcode_destination: platform=iOS Simulator,OS=13.0,name=iPhone 11 Pro Max diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/Info.plist b/AppWithModules/Frameworks/TNSWidgets.xcframework/Info.plist deleted file mode 100644 index e711b474..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/Info.plist +++ /dev/null @@ -1,40 +0,0 @@ - - - - - AvailableLibraries - - - LibraryIdentifier - ios-arm64_x86_64-simulator - LibraryPath - TNSWidgets.framework - SupportedArchitectures - - arm64 - x86_64 - - SupportedPlatform - ios - SupportedPlatformVariant - simulator - - - LibraryIdentifier - ios-arm64 - LibraryPath - TNSWidgets.framework - SupportedArchitectures - - arm64 - - SupportedPlatform - ios - - - CFBundlePackageType - XFWK - XCFrameworkFormatVersion - 1.0 - - diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSData+Async.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSData+Async.h deleted file mode 100644 index 36508cc5..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSData+Async.h +++ /dev/null @@ -1,24 +0,0 @@ -// -// NSData+Async.h -// TNSWidgets -// -// Created by Peter Staev on 7.08.19. -// Copyright © 2019 Telerik A D. All rights reserved. -// - -#import - -NS_ASSUME_NONNULL_BEGIN - -@interface NSData (Async) - -+ (void)dataWithContentsOfFile:(nonnull NSString*)path - completion:(void (^) (NSData*))callback; - -- (void)writeToFile:(nonnull NSString*) path - atomically:(BOOL)atomically - completion:(void (^) ())callback; - -@end - -NS_ASSUME_NONNULL_END diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSString+Async.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSString+Async.h deleted file mode 100644 index 2f059226..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSString+Async.h +++ /dev/null @@ -1,25 +0,0 @@ -// -// NSString+Async.h -// TNSWidgets -// -// Created by Peter Staev on 5.08.19. -// Copyright © 2019 Telerik A D. All rights reserved. -// - -#import - -NS_ASSUME_NONNULL_BEGIN - -@interface NSString (Async) - -+ (void)stringWithContentsOfFile:(nonnull NSString*)path - encoding:(NSStringEncoding)enc - completion:(void (^) (NSString*, NSError*))callback; - -- (void)writeToFile:(nonnull NSString*) path - atomically:(BOOL)atomically - encoding:(NSStringEncoding)enc - completion:(void (^) (NSError*))callback; -@end - -NS_ASSUME_NONNULL_END diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSLabel.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSLabel.h deleted file mode 100644 index 1c170b9c..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSLabel.h +++ /dev/null @@ -1,16 +0,0 @@ -// -// TNSLabel.h -// TNSWidgets -// -// Created by Hristo Hristov on 6/9/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -#import - -@interface TNSLabel : UILabel - -@property(nonatomic) UIEdgeInsets padding; -@property(nonatomic) UIEdgeInsets borderThickness; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSProcess.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSProcess.h deleted file mode 100644 index baea9550..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSProcess.h +++ /dev/null @@ -1,29 +0,0 @@ -// -// TNSProcess.h -// TNSWidgets -// -// Created by Panayot Cankov on 15/05/2017. -// Copyright © 2017 Telerik A D. All rights reserved. -// - -#ifndef TNSProcess_h -#define TNSProcess_h - -#import - -/** - * Get the milliseconds since the process started. - */ -double __tns_uptime(); - -/** - * Provides access to NSLog. The runtime implementation of console.log is filtered in release. - * We rarely need to log in release but in cases such as when logging app startup times in release, - * this will be convenient shortcut to NSLog, NSLog is not exposed. - * - * Please note the {N} CLI may be filtering app output, prefixing the message with "CONSOLE LOG" - * will make the logs visible in "tns run ios --release" builds. - */ -void __nslog(NSString* message); - -#endif /* TNSProcess_h */ diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSWidgets.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSWidgets.h deleted file mode 100644 index 7da1d2ad..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSWidgets.h +++ /dev/null @@ -1,24 +0,0 @@ -// -// TNSWidgets.h -// TNSWidgets -// -// Created by Panayot Cankov on 4/27/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -#import - -//! Project version number for TNSWidgets. -FOUNDATION_EXPORT double TNSWidgetsVersionNumber; - -//! Project version string for TNSWidgets. -FOUNDATION_EXPORT const unsigned char TNSWidgetsVersionString[]; - -// In this header, you should import all the public headers of your framework using statements like #import - -#import "UIImage+TNSBlocks.h" -#import "UIView+PassThroughParent.h" -#import "TNSLabel.h" -#import "TNSProcess.h" -#import "NSString+Async.h" -#import "NSData+Async.h" diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h deleted file mode 100644 index 9e67228b..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +++ /dev/null @@ -1,26 +0,0 @@ -// -// UIImage+UIImage_Async.h -// TKImageAsync -// -// Created by Panayot Cankov on 4/18/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -@interface UIImage (TNSBlocks) - -/** - * Similar to imageNamed: however it runs on a separate queue so the UI thread is not blocked. - * It also draws the UIImage in a small thumb to force decoding potentially avoiding UI hicckups when displayed. - */ -+ (void) tns_safeDecodeImageNamed: (NSString*) name completion: (void (^) (UIImage*))callback; - -/** - * Same as imageNamed, however calls to this method are sinchronized to be thread safe in iOS8 along with calls to tns_safeImageNamed and tns_safeDecodeImageNamed:completion: - * imageNamed is thread safe in iOS 9 and later so in later versions this methods simply fallbacks to imageNamed: - */ -+ (UIImage*) tns_safeImageNamed: (NSString*) name; - -+ (void) tns_decodeImageWithData: (NSData*) data completion: (void (^) (UIImage*))callback; -+ (void) tns_decodeImageWidthContentsOfFile: (NSString*) file completion: (void (^) (UIImage*))callback; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIView+PassThroughParent.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIView+PassThroughParent.h deleted file mode 100644 index e5f68c56..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +++ /dev/null @@ -1,17 +0,0 @@ -// -// UIView+PassThroughParent.h -// TNSWidgets -// -// Created by Manol Donev on 21.08.18. -// Copyright © 2018 Telerik A D. All rights reserved. -// - -#import - - -@interface UIView (PassThroughParent) - -- (BOOL) passThroughParent; -- (void) setPassThroughParent:(BOOL) passThroughParent; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Info.plist b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Info.plist deleted file mode 100644 index cad030baab756b2f733675647b9f1bd9e5677620..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 789 zcmY*W%Wl&^6!i>`mS?98w6sm3^g($V+bStpArez5s?vtqX+l+MP3(y~>iB^lQL_LE zi3L)H5bA<0u{4SRr+b*fU9N0<*dI+;h&=y>}WuqhTaT-_a<5Cr+L^JurCY z?78z7E)JpLk<6vbqhnXbCnm?UQ&+EDpP8MTpS`hg^VaQq2Fes-%B(Urcc@F&v@SBx zcyYN9yA~rVX%Xi64soM(VpGpG&`8QX*&}8g;RYlB6iXJD(k3N=fu>Sr$!&TnH6!lF zL3@J)A`>M=P_|lHCof_e5UWQNv5y;+(TI|;sz?PT zzfRmueO0Sb%O(+DXwnO8k*`i$Bs2r+M`EAVa-yU!muoAU%#%m_9ZuJ2WykCM^HbSC zGp6T=*!LL`dDgu`C^FV^M3Z6H7G*=K$`1=m`8xGGE-%#OMN!#GQ3vRQ9LRykKm!fX0yzfS=$P{Dv7g2D5M)&cg*LK?T;}bJ&Eta1XwOZ{S -#import - - -@interface NSObject (Swizzling) - -+ (void)swizzleInstanceMethodWithOriginalSelector:(SEL)originalSelector fromClass:(Class)classContainigOriginalSel withSwizzlingSelector:(SEL)swizzlingSelector; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h deleted file mode 100644 index 65ccdf02..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +++ /dev/null @@ -1,18 +0,0 @@ -// -// UIView+PropertyBag.h -// TNSWidgets -// -// Created by Manol Donev on 21.08.18. -// Copyright © 2018 Telerik A D. All rights reserved. -// - -#import -#import - - -@interface UIView (PropertyBag) - -- (id) propertyValueForKey:(NSString*) key; -- (void) setPropertyValue:(id) value forKey:(NSString*) key; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/TNSWidgets b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/TNSWidgets deleted file mode 100755 index 6c58b567aaeec6b413b7c3c46f838c744e73fe7c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 190408 zcmeEv3tUvy_WwRJ!_3HYRMb&{1~EhPF+4OttQiIs%?CazN{bmD3dzd>6}4=JL7~Dz zGsCh1wNmPKscWTW$-|723?G%Lc|obvtV`-GEzSRTod*mf*6s88J^ugyXU>OVuf6u# zYp=ET+K+S2-e-UI>kq$sGsZDoO8olbcL|7}vE=003<=een$QdUxkm7&BkK`*@ns>c?+(Sank3@Z? z_>K9c<`-BqbLNW#uJScLEF}CWrc3cZ;Fp_|-{~-}{C2DmawdulC=NHh;gy`cC}&A# zPFiwi&b(Yux$;v#B4oWNa-evZ`gP$o}3(SoNaVUw281m3|-5!kUb|GLCcjl)8evp_( zL2`1cOFeYeS7R55OGQ7SxHCT|Ry+uP^PC;U)qWL4LJpglk>Y>Mud`ibW#$*S^3ys5 zMrx5C#a;Lb9i5miwKGcral5`gbRs{!NKf(qfL~5ls=(1zzC@9qBm~9(1Adv=mig)A z%C7v(B0ouAivN)xOZrNc?8+}gPePKj4?S*g~Vm z_4+ot@T2&DP#*TGN%~U!kNKtKcaFN( z>l-Ta(+O<(|IYlxYVSy;{v|s*H%CIa)^CD~d_?z0{P=zuG|9UNIn{plao^x<)me$1LUt8@k{ws)TmY@yg@*6CEy1>lcwD{K7P_{k+4>fr}38V zT&r*;vYWB2Q_hhEcPcO(HInRn|!jfF;0w*Njx7+l{%TTTv zff=E}$ssH2WlRr4G=C^#El8&%DogW`jIBqQcR;= zyk?ZwO#)5(sGNUn`ef`opN{Tbbw0^+{_MJyHv^|3dKqStGG8`KiW3gkaQrAA&(uJG z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Kxjbbfl07Os>EtQ{`kPbww^qVGr=z#6en^D_T8f6pq+}Wb`MXuO%j97I>%(Ds zO&Rh3z=gf4JMEv=f;v(Y(6H;SK|hVyy9WQjg?-fEpVcy8E9G2cj^oB~x+jmreZTwp z$#}M~#FWR+S$(I8gt;4lL~aDXwrsEJ_c^%^RA%mergui}Uw11^h3n0@b;BMT+>I3< zwA;IKbnhipmJ?6GozOt?ZrymY#NST!&R(PvQvK#^H5Zj^FuOA!K%Xc}+@WyK1;x#Q z*~4o`k=_l~w?uk@EerQMT$3efY5L}?GO)CFqtX3je^*(gip2JkreSuWn_x**ylf{; z9M6h!z?KGFZMb=K?gl)QlIe@nmJKAbLcer@J~d-*UqYEn7iVT?ELfJ+O9B6o zwV&(_`mDM07cX7ayBxxAA->T3&!wJHdoJUZyUTuk*Ib{Jw`TW!9*X0+5$vNl*D2P^ z=8rg8V;DcQn;g|Lv@D_OEefzop8DHdzN26}HP tyMW%G%H~$9+ywU%A1~146(XH(E=27xg_gOp@Z-OjPZB065gTjD{|78oo3{V} diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h deleted file mode 100644 index 36508cc5..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h +++ /dev/null @@ -1,24 +0,0 @@ -// -// NSData+Async.h -// TNSWidgets -// -// Created by Peter Staev on 7.08.19. -// Copyright © 2019 Telerik A D. All rights reserved. -// - -#import - -NS_ASSUME_NONNULL_BEGIN - -@interface NSData (Async) - -+ (void)dataWithContentsOfFile:(nonnull NSString*)path - completion:(void (^) (NSData*))callback; - -- (void)writeToFile:(nonnull NSString*) path - atomically:(BOOL)atomically - completion:(void (^) ())callback; - -@end - -NS_ASSUME_NONNULL_END diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h deleted file mode 100644 index 2f059226..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h +++ /dev/null @@ -1,25 +0,0 @@ -// -// NSString+Async.h -// TNSWidgets -// -// Created by Peter Staev on 5.08.19. -// Copyright © 2019 Telerik A D. All rights reserved. -// - -#import - -NS_ASSUME_NONNULL_BEGIN - -@interface NSString (Async) - -+ (void)stringWithContentsOfFile:(nonnull NSString*)path - encoding:(NSStringEncoding)enc - completion:(void (^) (NSString*, NSError*))callback; - -- (void)writeToFile:(nonnull NSString*) path - atomically:(BOOL)atomically - encoding:(NSStringEncoding)enc - completion:(void (^) (NSError*))callback; -@end - -NS_ASSUME_NONNULL_END diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h deleted file mode 100644 index 1c170b9c..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h +++ /dev/null @@ -1,16 +0,0 @@ -// -// TNSLabel.h -// TNSWidgets -// -// Created by Hristo Hristov on 6/9/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -#import - -@interface TNSLabel : UILabel - -@property(nonatomic) UIEdgeInsets padding; -@property(nonatomic) UIEdgeInsets borderThickness; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h deleted file mode 100644 index baea9550..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h +++ /dev/null @@ -1,29 +0,0 @@ -// -// TNSProcess.h -// TNSWidgets -// -// Created by Panayot Cankov on 15/05/2017. -// Copyright © 2017 Telerik A D. All rights reserved. -// - -#ifndef TNSProcess_h -#define TNSProcess_h - -#import - -/** - * Get the milliseconds since the process started. - */ -double __tns_uptime(); - -/** - * Provides access to NSLog. The runtime implementation of console.log is filtered in release. - * We rarely need to log in release but in cases such as when logging app startup times in release, - * this will be convenient shortcut to NSLog, NSLog is not exposed. - * - * Please note the {N} CLI may be filtering app output, prefixing the message with "CONSOLE LOG" - * will make the logs visible in "tns run ios --release" builds. - */ -void __nslog(NSString* message); - -#endif /* TNSProcess_h */ diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h deleted file mode 100644 index 7da1d2ad..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h +++ /dev/null @@ -1,24 +0,0 @@ -// -// TNSWidgets.h -// TNSWidgets -// -// Created by Panayot Cankov on 4/27/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -#import - -//! Project version number for TNSWidgets. -FOUNDATION_EXPORT double TNSWidgetsVersionNumber; - -//! Project version string for TNSWidgets. -FOUNDATION_EXPORT const unsigned char TNSWidgetsVersionString[]; - -// In this header, you should import all the public headers of your framework using statements like #import - -#import "UIImage+TNSBlocks.h" -#import "UIView+PassThroughParent.h" -#import "TNSLabel.h" -#import "TNSProcess.h" -#import "NSString+Async.h" -#import "NSData+Async.h" diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h deleted file mode 100644 index 9e67228b..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +++ /dev/null @@ -1,26 +0,0 @@ -// -// UIImage+UIImage_Async.h -// TKImageAsync -// -// Created by Panayot Cankov on 4/18/16. -// Copyright © 2016 Telerik A D. All rights reserved. -// - -@interface UIImage (TNSBlocks) - -/** - * Similar to imageNamed: however it runs on a separate queue so the UI thread is not blocked. - * It also draws the UIImage in a small thumb to force decoding potentially avoiding UI hicckups when displayed. - */ -+ (void) tns_safeDecodeImageNamed: (NSString*) name completion: (void (^) (UIImage*))callback; - -/** - * Same as imageNamed, however calls to this method are sinchronized to be thread safe in iOS8 along with calls to tns_safeImageNamed and tns_safeDecodeImageNamed:completion: - * imageNamed is thread safe in iOS 9 and later so in later versions this methods simply fallbacks to imageNamed: - */ -+ (UIImage*) tns_safeImageNamed: (NSString*) name; - -+ (void) tns_decodeImageWithData: (NSData*) data completion: (void (^) (UIImage*))callback; -+ (void) tns_decodeImageWidthContentsOfFile: (NSString*) file completion: (void (^) (UIImage*))callback; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h deleted file mode 100644 index e5f68c56..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +++ /dev/null @@ -1,17 +0,0 @@ -// -// UIView+PassThroughParent.h -// TNSWidgets -// -// Created by Manol Donev on 21.08.18. -// Copyright © 2018 Telerik A D. All rights reserved. -// - -#import - - -@interface UIView (PassThroughParent) - -- (BOOL) passThroughParent; -- (void) setPassThroughParent:(BOOL) passThroughParent; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Info.plist b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Info.plist deleted file mode 100644 index b4b13b7011c45fbe0d55d8a74ceaa1b98133cd26..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 769 zcmZ9JOK;Oa5XX0ywv=Z!4TUtNJi_}S%eGP=r%0(ADT>mjwbMWq)j0OXS+Rb|u>+A1 zNJt3v*e`$t-=JRraYEwWJD&j#TsY88Y7<~DGxMMM?as`0d`A1BD1O895FMMEo;f~y z;^e8*XU?W@dM_ap}^PtNCl!^EYnZx_w8-nQ}y#RX5BYb;-Iqj&!`R zQYlBS#fU-%gn7P0+;EfF)N^$_m*iGo5Hkvm4kLewRg0I>E+v7Emy*h=+w~M`hMYHo z;T8${+-oPQSc8C`94R8 z)nG>0^#Z4_<5U8~7i}xris$&0jk--KT2eaR!pM%VKCcLWD#??<0jk}}5mZCj2 zJ&Uws8?O}CsY{*6Syy9tr&;COr6#Eu4rRlpESBZsCULj5HMK=8n}odMMK7=gJ{uj7 zz8O$I6ed~qfgoy?daI^N+$r(%;W8hCHhP{*RQ?tp+zU1&9p_EY5e(mFMBv_d-oC)t zz!6MlxV9kaVpDolepnpg{s`|UxF!_@ng7mz@<`PrSr)e>xm;N8s6|2kc=sNL7=c-^ z3~ImzFTozz2cN(J_ztIG9u{B;ZosE7gsFZdfxp&67# hIaETcsD;`nK+n-D^ai~}@4)yVcx1u-*v1C!9s&@ -#import - - -@interface NSObject (Swizzling) - -+ (void)swizzleInstanceMethodWithOriginalSelector:(SEL)originalSelector fromClass:(Class)classContainigOriginalSel withSwizzlingSelector:(SEL)swizzlingSelector; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h deleted file mode 100644 index 65ccdf02..00000000 --- a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +++ /dev/null @@ -1,18 +0,0 @@ -// -// UIView+PropertyBag.h -// TNSWidgets -// -// Created by Manol Donev on 21.08.18. -// Copyright © 2018 Telerik A D. All rights reserved. -// - -#import -#import - - -@interface UIView (PropertyBag) - -- (id) propertyValueForKey:(NSString*) key; -- (void) setPropertyValue:(id) value forKey:(NSString*) key; - -@end diff --git a/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/TNSWidgets b/AppWithModules/Frameworks/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/TNSWidgets deleted file mode 100755 index 2d6cea4aef345c9af08e006ef07fd966bd968bc6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 159904 zcmeIb3w)Ht^*=njn@ALd0103f3@HABA_hn>MA1z`V51?#BuG?n*=#msCD{$Tn{X2i z0!kXt&|-_#YOGcv-ms;WTCGtK(0T!{)Ss7twg#_MC;}Gqe$QNXpM5q7wEBPlpZD|5 z1JBN!GiT16^PTH6o1N$7@1On)W6Ww{tQSHXV|E1JwBVyJczqBuX0hW=YeB3pZhdJ4 zGy)m{jetf#BcKt`2xtT}0vZ90fJQ(gpb^jrXaqC@8Uc-fMnEH=5zq)|1T+E~0gZr0 zKqH_L&VG9mp*+`CK)gnEE&(^?fUqC|aqBvK36J&t2^b21%jWzOOG4 zIdh}}MV~+)*%w+=8*AU#OGVBd5|;OBxxVfX3Ugs3aMYLMO+EAc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aYsu6amPM=;pn5&wA;__pzHF{au-V`~J$dxOaE& zo@bq27T*L-n61|A2oU{8#dv;k8fSkcgh>TpSEm+yY|L&pZ(>+M;mT^?XUL?bWN*$>ynY9 zimv!PxB7TWua0G>j~iCox8n5=&}OOi@-}(w!`>862sb<((FkY+Gy)m{jetf#BcKt` z2xtT}0vZ90fJQ(gpb^jrXaqC@8Uc-fMnEH=5zq)|1T+E~0gZr0KqH_L& - - - - files - - Headers/NSData+Async.h - - Tq5PZtZ9yZpT27t8LYzxs99+tIc= - - Headers/NSString+Async.h - - o8366y9zYMOVyObC3vtKKy/8jxA= - - Headers/TNSLabel.h - - x8V4jT6oNNls+KE3y/DE6ij9eCk= - - Headers/TNSProcess.h - - eH8JxX7eF01jI5kObW6erxNNpvA= - - Headers/TNSWidgets.h - - gUvu5bjZg5Aie5iJ1krxFmDrHwk= - - Headers/UIImage+TNSBlocks.h - - OzGlvoGOJcFC6Z+YR5xThjLTUK4= - - Headers/UIView+PassThroughParent.h - - zdxBV/QJg7NPyx04RmZrXsxbHKU= - - Info.plist - - yunikXlPeT1W+ojfouU5/psY+og= - - Modules/module.modulemap - - ANIiDnbrCY8YCOtOm1xDrUyt8do= - - PrivateHeaders/NSObject+Swizzling.h - - wRUUMHgrTVWHd/e8bDqN8sYZth4= - - PrivateHeaders/UIView+PropertyBag.h - - 3USXIiZgky+5k7en+R6oyZ3pP18= - - - files2 - - Headers/NSData+Async.h - - hash - - Tq5PZtZ9yZpT27t8LYzxs99+tIc= - - hash2 - - p5/yRf/rWsA01xpYhJt8SFVMVvX2u8dD/1LMd4rOCg4= - - - Headers/NSString+Async.h - - hash - - o8366y9zYMOVyObC3vtKKy/8jxA= - - hash2 - - 1Iuk4atAJ89zujXqrLBvGz7Ny52RXNdD5c1ZMK0SFgs= - - - Headers/TNSLabel.h - - hash - - x8V4jT6oNNls+KE3y/DE6ij9eCk= - - hash2 - - uaE78Ar4SA7jzBIQrT3lTvBQFOQj1sf1ippa8ldUDqQ= - - - Headers/TNSProcess.h - - hash - - eH8JxX7eF01jI5kObW6erxNNpvA= - - hash2 - - HzT5FVe/Y4alUoeUzAS0wSMLOmnnb7o1+Ay+kqbVFMo= - - - Headers/TNSWidgets.h - - hash - - gUvu5bjZg5Aie5iJ1krxFmDrHwk= - - hash2 - - V99t2zLwRPOs90tbGiQbhbdAFJlW7mp7X2R5337ewUA= - - - Headers/UIImage+TNSBlocks.h - - hash - - OzGlvoGOJcFC6Z+YR5xThjLTUK4= - - hash2 - - MgrX2woetySmXcrrDF290WGxNiW5W3E0B0fsjy8BgNI= - - - Headers/UIView+PassThroughParent.h - - hash - - zdxBV/QJg7NPyx04RmZrXsxbHKU= - - hash2 - - UfHyaUaTFlNcY5M7lUKwq6bPGuQeVIbjhCCInN1ZEYA= - - - Modules/module.modulemap - - hash - - ANIiDnbrCY8YCOtOm1xDrUyt8do= - - hash2 - - geXwbECY3V3psdekq89Ia+2j4/OludM5UatqEk+xhhc= - - - PrivateHeaders/NSObject+Swizzling.h - - hash - - wRUUMHgrTVWHd/e8bDqN8sYZth4= - - hash2 - - S+GqZzjPH/SqyxwzyysFybjZsbwS5lxcTwL04W79IGA= - - - PrivateHeaders/UIView+PropertyBag.h - - hash - - 3USXIiZgky+5k7en+R6oyZ3pP18= - - hash2 - - /qFTteGRAX+GloVCipAdNRXPDPDWsNmQ+9USxt99lXE= - - - - rules - - ^.* - - ^.*\.lproj/ - - optional - - weight - 1000 - - ^.*\.lproj/locversion.plist$ - - omit - - weight - 1100 - - ^Base\.lproj/ - - weight - 1010 - - ^version.plist$ - - - rules2 - - .*\.dSYM($|/) - - weight - 11 - - ^(.*/)?\.DS_Store$ - - omit - - weight - 2000 - - ^.* - - ^.*\.lproj/ - - optional - - weight - 1000 - - ^.*\.lproj/locversion.plist$ - - omit - - weight - 1100 - - ^Base\.lproj/ - - weight - 1010 - - ^Info\.plist$ - - omit - - weight - 20 - - ^PkgInfo$ - - omit - - weight - 20 - - ^embedded\.provisionprofile$ - - weight - 20 - - ^version\.plist$ - - weight - 20 - - - - diff --git a/AppWithModules/Info.plist b/AppWithModules/Info.plist deleted file mode 100644 index e1ab7379..00000000 --- a/AppWithModules/Info.plist +++ /dev/null @@ -1,37 +0,0 @@ - - - - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - $(PRODUCT_NAME) - CFBundlePackageType - APPL - CFBundleShortVersionString - 1.0 - CFBundleVersion - 1 - LSRequiresIPhoneOS - - UIRequiredDeviceCapabilities - - armv7 - - UISupportedInterfaceOrientations - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - - diff --git a/AppWithModules/Source Files/main.m b/AppWithModules/Source Files/main.m deleted file mode 100644 index dacca262..00000000 --- a/AppWithModules/Source Files/main.m +++ /dev/null @@ -1,32 +0,0 @@ -#import - -extern char startOfMetadataSection __asm("section$start$__DATA$__TNSMetadata"); -NativeScript* nativescript; - -int main(int argc, char *argv[]) { - @autoreleasepool { - void* metadataPtr = &startOfMetadataSection; - - NSString* baseDir = [[NSBundle mainBundle] resourcePath]; - - bool isDebug = -#ifdef DEBUG - true; -#else - false; -#endif - - Config* config = [[Config alloc] init]; - config.IsDebug = isDebug; - config.LogToSystemConsole = isDebug; - config.MetadataPtr = metadataPtr; - config.BaseDir = baseDir; - config.ArgumentsCount = argc; - config.Arguments = argv; - - nativescript = [[NativeScript alloc] initWithConfig: config]; - [nativescript runMainApplication]; - - return 0; - } -} diff --git a/AppWithModules/app/bundle.js b/AppWithModules/app/bundle.js deleted file mode 100644 index 634e347e..00000000 --- a/AppWithModules/app/bundle.js +++ /dev/null @@ -1,394 +0,0 @@ -require("./runtime.js");require("./vendor.js");module.exports = -(global["webpackJsonp"] = global["webpackJsonp"] || []).push([["bundle"],{ - -/***/ "../$$_lazy_route_resource lazy recursive": -/***/ (function(module, exports) { - -function webpackEmptyAsyncContext(req) { - // Here Promise.resolve().then() is used instead of new Promise() to prevent - // uncaught exception popping up in devtools - return Promise.resolve().then(function() { - var e = new Error("Cannot find module '" + req + "'"); - e.code = 'MODULE_NOT_FOUND'; - throw e; - }); -} -webpackEmptyAsyncContext.keys = function() { return []; }; -webpackEmptyAsyncContext.resolve = webpackEmptyAsyncContext; -module.exports = webpackEmptyAsyncContext; -webpackEmptyAsyncContext.id = "../$$_lazy_route_resource lazy recursive"; - -/***/ }), - -/***/ "./app.css": -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(global) {exports = module.exports = __webpack_require__("../node_modules/css-loader/dist/runtime/api.js")(false); -// Imports -exports.i(__webpack_require__("../node_modules/css-loader/dist/cjs.js?!../node_modules/nativescript-theme-core/css/core.light.css"), ""); - -// Module -exports.push([module.i, "/*\nIn NativeScript, the app.css file is where you place CSS rules that\nyou would like to apply to your entire application. Check out\nhttp://docs.nativescript.org/ui/styling for a full list of the CSS\nselectors and properties you can use to style UI components.\n\n/*\nIn many cases you may want to use the NativeScript core theme instead\nof writing your own CSS rules. For a full list of class names in the theme\nrefer to http://docs.nativescript.org/ui/theme.\n*/\n", ""]); - -; - if (true) { - module.hot.accept(); - module.hot.dispose(() => { - global.hmrRefresh({ type: 'style', path: './app.css' }); - }) - } - -/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("../node_modules/webpack/buildin/global.js"))) - -/***/ }), - -/***/ "./app/app-routing.module.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AppRoutingModule", function() { return AppRoutingModule; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); -/* harmony import */ var nativescript_angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../node_modules/nativescript-angular/router/index.js"); -/* harmony import */ var nativescript_angular_router__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(nativescript_angular_router__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _item_items_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./app/item/items.component.ts"); -/* harmony import */ var _item_item_detail_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("./app/item/item-detail.component.ts"); - - - - -var routes = [ - { path: "", redirectTo: "/items", pathMatch: "full" }, - { path: "items", component: _item_items_component__WEBPACK_IMPORTED_MODULE_2__["ItemsComponent"] }, - { path: "item/:id", component: _item_item_detail_component__WEBPACK_IMPORTED_MODULE_3__["ItemDetailComponent"] } -]; -var AppRoutingModule = /** @class */ (function () { - function AppRoutingModule() { - } - AppRoutingModule = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({ - imports: [nativescript_angular_router__WEBPACK_IMPORTED_MODULE_1__["NativeScriptRouterModule"].forRoot(routes)], - exports: [nativescript_angular_router__WEBPACK_IMPORTED_MODULE_1__["NativeScriptRouterModule"]] - }) - ], AppRoutingModule); - return AppRoutingModule; -}()); - - - -/***/ }), - -/***/ "./app/app.component.html": -/***/ (function(module, exports) { - -module.exports = "\n\n" - -/***/ }), - -/***/ "./app/app.component.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AppComponent", function() { return AppComponent; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); - -var AppComponent = /** @class */ (function () { - function AppComponent() { - } - AppComponent = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"])({ - selector: "ns-app", - template: __webpack_require__("./app/app.component.html") - }) - ], AppComponent); - return AppComponent; -}()); - - - -/***/ }), - -/***/ "./app/app.module.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AppModule", function() { return AppModule; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); -/* harmony import */ var nativescript_angular_nativescript_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../node_modules/nativescript-angular/nativescript.module.js"); -/* harmony import */ var nativescript_angular_nativescript_module__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(nativescript_angular_nativescript_module__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _app_routing_module__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./app/app-routing.module.ts"); -/* harmony import */ var _app_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("./app/app.component.ts"); -/* harmony import */ var _item_items_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("./app/item/items.component.ts"); -/* harmony import */ var _item_item_detail_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("./app/item/item-detail.component.ts"); - - - - - - -// Uncomment and add to NgModule imports if you need to use two-way binding -// import { NativeScriptFormsModule } from "nativescript-angular/forms"; -// Uncomment and add to NgModule imports if you need to use the HttpClient wrapper -// import { NativeScriptHttpClientModule } from "nativescript-angular/http-client"; -var AppModule = /** @class */ (function () { - /* - Pass your application module to the bootstrapModule function located in main.ts to start your app - */ - function AppModule() { - } - AppModule = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({ - bootstrap: [ - _app_component__WEBPACK_IMPORTED_MODULE_3__["AppComponent"] - ], - imports: [ - nativescript_angular_nativescript_module__WEBPACK_IMPORTED_MODULE_1__["NativeScriptModule"], - _app_routing_module__WEBPACK_IMPORTED_MODULE_2__["AppRoutingModule"] - ], - declarations: [ - _app_component__WEBPACK_IMPORTED_MODULE_3__["AppComponent"], - _item_items_component__WEBPACK_IMPORTED_MODULE_4__["ItemsComponent"], - _item_item_detail_component__WEBPACK_IMPORTED_MODULE_5__["ItemDetailComponent"] - ], - providers: [], - schemas: [ - _angular_core__WEBPACK_IMPORTED_MODULE_0__["NO_ERRORS_SCHEMA"] - ] - }) - /* - Pass your application module to the bootstrapModule function located in main.ts to start your app - */ - ], AppModule); - return AppModule; -}()); - - - -/***/ }), - -/***/ "./app/item/item-detail.component.html": -/***/ (function(module, exports) { - -module.exports = "\n\n \n \n \n \n \n\n" - -/***/ }), - -/***/ "./app/item/item-detail.component.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ItemDetailComponent", function() { return ItemDetailComponent; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); -/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../node_modules/@angular/router/fesm5/router.js"); -/* harmony import */ var tns_core_modules_http__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("../node_modules/tns-core-modules/http/http.js"); -/* harmony import */ var tns_core_modules_http__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(tns_core_modules_http__WEBPACK_IMPORTED_MODULE_2__); -/* harmony import */ var _item_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("./app/item/item.service.ts"); - - - - -var ItemDetailComponent = /** @class */ (function () { - function ItemDetailComponent(itemService, route) { - this.itemService = itemService; - this.route = route; - } - ItemDetailComponent.prototype.ngOnInit = function () { - var id = +this.route.snapshot.params.id; - this.item = this.itemService.getItem(id); - - Object(tns_core_modules_http__WEBPACK_IMPORTED_MODULE_2__["request"])({ - url: "https://httpbin.org/post", - method: "POST", - headers: { "Content-Type": "application/json" }, - content: JSON.stringify({ - username: "usr", - password: "pwd" - }) - }).then(function (response) { - console.log(response.content.toString()); - }, function (e) { - console.log(e); - }); - - - // Object(tns_core_modules_http__WEBPACK_IMPORTED_MODULE_2__["getString"])("https://httpbin.org/get").then(function (r) { - // console.log(r); - // }, function (e) { - // console.log(e); - // }); - }; - ItemDetailComponent.ctorParameters = function () { return [ - { type: _item_service__WEBPACK_IMPORTED_MODULE_3__["ItemService"] }, - { type: _angular_router__WEBPACK_IMPORTED_MODULE_1__["ActivatedRoute"] } - ]; }; - ItemDetailComponent = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"])({ - selector: "ns-details", - template: __webpack_require__("./app/item/item-detail.component.html") - }), - __metadata("design:paramtypes", [_item_service__WEBPACK_IMPORTED_MODULE_3__["ItemService"], - _angular_router__WEBPACK_IMPORTED_MODULE_1__["ActivatedRoute"]]) - ], ItemDetailComponent); - return ItemDetailComponent; -}()); - - - -/***/ }), - -/***/ "./app/item/item.service.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ItemService", function() { return ItemService; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); - -var ItemService = /** @class */ (function () { - function ItemService() { - this.items = new Array({ id: 1, name: "Ter Stegen", role: "Goalkeeper" }, { id: 3, name: "Piqué", role: "Defender" }, { id: 4, name: "I. Rakitic", role: "Midfielder" }, { id: 5, name: "Sergio", role: "Midfielder" }, { id: 6, name: "Denis Suárez", role: "Midfielder" }, { id: 7, name: "Arda", role: "Midfielder" }, { id: 8, name: "A. Iniesta", role: "Midfielder" }, { id: 9, name: "Suárez", role: "Forward" }, { id: 10, name: "Messi", role: "Forward" }, { id: 11, name: "Neymar", role: "Forward" }, { id: 12, name: "Rafinha", role: "Midfielder" }, { id: 13, name: "Cillessen", role: "Goalkeeper" }, { id: 14, name: "Mascherano", role: "Defender" }, { id: 17, name: "Paco Alcácer", role: "Forward" }, { id: 18, name: "Jordi Alba", role: "Defender" }, { id: 19, name: "Digne", role: "Defender" }, { id: 20, name: "Sergi Roberto", role: "Midfielder" }, { id: 21, name: "André Gomes", role: "Midfielder" }, { id: 22, name: "Aleix Vidal", role: "Midfielder" }, { id: 23, name: "Umtiti", role: "Defender" }, { id: 24, name: "Mathieu", role: "Defender" }, { id: 25, name: "Masip", role: "Goalkeeper" }); - } - ItemService.prototype.getItems = function () { - return this.items; - }; - ItemService.prototype.getItem = function (id) { - return this.items.filter(function (item) { return item.id === id; })[0]; - }; - ItemService = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])({ - providedIn: "root" - }) - ], ItemService); - return ItemService; -}()); - - - -/***/ }), - -/***/ "./app/item/items.component.html": -/***/ (function(module, exports) { - -module.exports = "\n\n\n\n\n\n\n\n \n \n \n \n \n\n" - -/***/ }), - -/***/ "./app/item/items.component.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ItemsComponent", function() { return ItemsComponent; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); -/* harmony import */ var _item_service__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./app/item/item.service.ts"); - - -var ItemsComponent = /** @class */ (function () { - function ItemsComponent(itemService) { - this.itemService = itemService; - } - ItemsComponent.prototype.ngOnInit = function () { - this.items = this.itemService.getItems(); - }; - ItemsComponent.ctorParameters = function () { return [ - { type: _item_service__WEBPACK_IMPORTED_MODULE_1__["ItemService"] } - ]; }; - ItemsComponent = __decorate([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"])({ - selector: "ns-items", - template: __webpack_require__("./app/item/items.component.html") - }), - __metadata("design:paramtypes", [_item_service__WEBPACK_IMPORTED_MODULE_1__["ItemService"]]) - ], ItemsComponent); - return ItemsComponent; -}()); - - - -/***/ }), - -/***/ "./main.ts": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var nativescript_angular_platform__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/nativescript-angular/platform.js"); -/* harmony import */ var nativescript_angular_platform__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(nativescript_angular_platform__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _app_app_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./app/app.module.ts"); - - __webpack_require__("../node_modules/nativescript-dev-webpack/load-application-css-angular.js")(); - - - if (true) { - const hmrUpdate = __webpack_require__("../node_modules/nativescript-dev-webpack/hmr/index.js").hmrUpdate; - global.__initialHmrUpdate = true; - global.__hmrSyncBackup = global.__onLiveSync; - - global.__onLiveSync = function () { - hmrUpdate(); - }; - - global.hmrRefresh = function({ type, path } = {}) { - if (global.__initialHmrUpdate) { - return; - } - - setTimeout(() => { - global.__hmrSyncBackup({ type, path }); - }); - }; - - hmrUpdate().then(() => { - global.__initialHmrUpdate = false; - }) - } - - - __webpack_require__("../node_modules/tns-core-modules/bundle-entry-points.js"); - - -var options_Generated = {}; - -if (true) { - options_Generated = { - hmrOptions: { - moduleTypeFactory: function () { return __webpack_require__("./app/app.module.ts").AppModule; }, - livesyncCallback: function (platformReboot) { setTimeout(platformReboot, 0); } - } - }; -} - -if (true) { - module["hot"].accept(["./app/app.module.ts"], function(__WEBPACK_OUTDATED_DEPENDENCIES__) { /* harmony import */ _app_app_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./app/app.module.ts"); -(function () { - global["hmrRefresh"]({}); - })(__WEBPACK_OUTDATED_DEPENDENCIES__); }); -} -// A traditional NativeScript application starts by initializing global objects, -// setting up global CSS rules, creating, and navigating to the main page. -// Angular applications need to take care of their own initialization: -// modules, components, directives, routes, DI providers. -// A NativeScript Angular app needs to make both paradigms work together, -// so we provide a wrapper platform object, platformNativeScriptDynamic, -// that sets up a NativeScript application and can bootstrap the Angular framework. -nativescript_angular_platform__WEBPACK_IMPORTED_MODULE_0__["platformNativeScriptDynamic"](Object.assign({}, options_Generated)).bootstrapModule(_app_app_module__WEBPACK_IMPORTED_MODULE_1__["AppModule"]); - - - - -/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("../node_modules/webpack/buildin/global.js"))) - -/***/ }), - -/***/ "./package.json": -/***/ (function(module) { - -module.exports = {"main":"main.js","android":{"v8Flags":"--expose_gc","markingMode":"none"}}; - -/***/ }) - -},[["./main.ts","runtime","vendor"]]]); -//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi4vJF9sYXp5X3JvdXRlX3Jlc291cmNlIGxhenkgbmFtZXNwYWNlIG9iamVjdCIsIndlYnBhY2s6Ly8vLi9hcHAuY3NzIiwid2VicGFjazovLy8uL2FwcC9hcHAtcm91dGluZy5tb2R1bGUudHMiLCJ3ZWJwYWNrOi8vLy4vYXBwL2FwcC5jb21wb25lbnQuaHRtbCIsIndlYnBhY2s6Ly8vLi9hcHAvYXBwLmNvbXBvbmVudC50cyIsIndlYnBhY2s6Ly8vLi9hcHAvYXBwLm1vZHVsZS50cyIsIndlYnBhY2s6Ly8vLi9hcHAvaXRlbS9pdGVtLWRldGFpbC5jb21wb25lbnQuaHRtbCIsIndlYnBhY2s6Ly8vLi9hcHAvaXRlbS9pdGVtLWRldGFpbC5jb21wb25lbnQudHMiLCJ3ZWJwYWNrOi8vLy4vYXBwL2l0ZW0vaXRlbS5zZXJ2aWNlLnRzIiwid2VicGFjazovLy8uL2FwcC9pdGVtL2l0ZW1zLmN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yIHBsYXRmb3JtIG9iamVjdCwgcGxhdGZvcm1OYXRpdmVTY3JpcHREeW5hbWljLFxuLy8gdGhhdCBzZXRzIHVwIGEgTmF0aXZlU2NyaXB0IGFwcGxpY2F0aW9uIGFuZCBjYW4gYm9vdHN0cmFwIHRoZSBBbmd1bGFyIGZyYW1ld29yay5cbnBsYXRmb3JtTmF0aXZlU2NyaXB0RHluYW1pYygpLmJvb3RzdHJhcE1vZHVsZShBcHBNb2R1bGUpO1xuIl0sInNvdXJjZVJvb3QiOiIifQ== \ No newline at end of file diff --git a/AppWithModules/app/package.json b/AppWithModules/app/package.json deleted file mode 100644 index c2396041..00000000 --- a/AppWithModules/app/package.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "main": "bundle", - "android": { - "v8Flags": "--expose_gc", - "markingMode": "none" - } -} \ No newline at end of file diff --git a/AppWithModules/app/runtime.js b/AppWithModules/app/runtime.js deleted file mode 100644 index 8bc3be72..00000000 --- a/AppWithModules/app/runtime.js +++ /dev/null @@ -1,829 +0,0 @@ -/******/ (function(modules) { // webpackBootstrap -/******/ // install a JSONP callback for chunk loading -/******/ function webpackJsonpCallback(data) { -/******/ var chunkIds = data[0]; -/******/ var moreModules = data[1]; -/******/ var executeModules = data[2]; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0, resolves = []; -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(installedChunks[chunkId]) { -/******/ resolves.push(installedChunks[chunkId][0]); -/******/ } -/******/ installedChunks[chunkId] = 0; -/******/ } -/******/ for(moduleId in moreModules) { -/******/ if(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) { -/******/ modules[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(parentJsonpFunction) parentJsonpFunction(data); -/******/ while(resolves.length) { -/******/ resolves.shift()(); -/******/ } -/******/ -/******/ // add entry modules from loaded chunk to deferred list -/******/ deferredModules.push.apply(deferredModules, executeModules || []); -/******/ -/******/ // run deferred modules when all chunks ready -/******/ return checkDeferredModules(); -/******/ }; -/******/ function checkDeferredModules() { -/******/ var result; -/******/ for(var i = 0; i < deferredModules.length; i++) { -/******/ var deferredModule = deferredModules[i]; -/******/ var fulfilled = true; -/******/ for(var j = 1; j < deferredModule.length; j++) { -/******/ var depId = deferredModule[j]; -/******/ if(installedChunks[depId] !== 0) fulfilled = false; -/******/ } -/******/ if(fulfilled) { -/******/ deferredModules.splice(i--, 1); -/******/ result = __webpack_require__(__webpack_require__.s = deferredModule[0]); -/******/ } -/******/ } -/******/ return result; -/******/ } -/******/ function hotDisposeChunk(chunkId) { -/******/ delete installedChunks[chunkId]; -/******/ } -/******/ var parentHotUpdateCallback = global["webpackHotUpdate"]; -/******/ global["webpackHotUpdate"] = function webpackHotUpdateCallback(chunkId, moreModules) { -/******/ hotAddUpdateChunk(chunkId, moreModules); -/******/ if (parentHotUpdateCallback) { -/******/ parentHotUpdateCallback(chunkId, moreModules); -/******/ } -/******/ } -/******/ -/******/ function hotDownloadUpdateChunk(chunkId) { -/******/ const requestPath = './' + "" + chunkId + "." + hotCurrentHash + ".hot-update.js"; -/******/ try { -/******/ require(requestPath); -/******/ } catch (e) { -/******/ console.log("Hot download for update chunk failed."); -/******/ console.error(e); -/******/ } -/******/ } -/******/ -/******/ function hotDownloadManifest() { -/******/ return new Promise(function (resolve, reject) { -/******/ const requestPath = './' + "" + hotCurrentHash + ".hot-update.json"; -/******/ try { -/******/ const update = require(requestPath); -/******/ resolve(update); -/******/ } catch (e) { -/******/ console.log("Hot download for manifest failed."); -/******/ console.error(e); -/******/ reject(e); -/******/ } -/******/ }); -/******/ } -/******/ -/******/ var hotApplyOnUpdate = true; -/******/ // eslint-disable-next-line no-unused-vars -/******/ var hotCurrentHash = "249e64153fa538947c6e"; -/******/ var hotRequestTimeout = 10000; -/******/ var hotCurrentModuleData = {}; -/******/ var hotCurrentChildModule; -/******/ // eslint-disable-next-line no-unused-vars -/******/ var hotCurrentParents = []; -/******/ // eslint-disable-next-line no-unused-vars -/******/ var hotCurrentParentsTemp = []; -/******/ -/******/ // eslint-disable-next-line no-unused-vars -/******/ function hotCreateRequire(moduleId) { -/******/ var me = installedModules[moduleId]; -/******/ if (!me) return __webpack_require__; -/******/ var fn = function(request) { -/******/ if (me.hot.active) { -/******/ if (installedModules[request]) { -/******/ if (installedModules[request].parents.indexOf(moduleId) === -1) { -/******/ installedModules[request].parents.push(moduleId); -/******/ } -/******/ } else { -/******/ hotCurrentParents = [moduleId]; -/******/ hotCurrentChildModule = request; -/******/ } -/******/ if (me.children.indexOf(request) === -1) { -/******/ me.children.push(request); -/******/ } -/******/ } else { -/******/ console.warn( -/******/ "[HMR] unexpected require(" + -/******/ request + -/******/ ") from disposed module " + -/******/ moduleId -/******/ ); -/******/ hotCurrentParents = []; -/******/ } -/******/ return __webpack_require__(request); -/******/ }; -/******/ var ObjectFactory = function ObjectFactory(name) { -/******/ return { -/******/ configurable: true, -/******/ enumerable: true, -/******/ get: function() { -/******/ return __webpack_require__[name]; -/******/ }, -/******/ set: function(value) { -/******/ __webpack_require__[name] = value; -/******/ } -/******/ }; -/******/ }; -/******/ for (var name in __webpack_require__) { -/******/ if ( -/******/ Object.prototype.hasOwnProperty.call(__webpack_require__, name) && -/******/ name !== "e" && -/******/ name !== "t" -/******/ ) { -/******/ Object.defineProperty(fn, name, ObjectFactory(name)); -/******/ } -/******/ } -/******/ fn.e = function(chunkId) { -/******/ if (hotStatus === "ready") hotSetStatus("prepare"); -/******/ hotChunksLoading++; -/******/ return __webpack_require__.e(chunkId).then(finishChunkLoading, function(err) { -/******/ finishChunkLoading(); -/******/ throw err; -/******/ }); -/******/ -/******/ function finishChunkLoading() { -/******/ hotChunksLoading--; -/******/ if (hotStatus === "prepare") { -/******/ if (!hotWaitingFilesMap[chunkId]) { -/******/ hotEnsureUpdateChunk(chunkId); -/******/ } -/******/ if (hotChunksLoading === 0 && hotWaitingFiles === 0) { -/******/ hotUpdateDownloaded(); -/******/ } -/******/ } -/******/ } -/******/ }; -/******/ fn.t = function(value, mode) { -/******/ if (mode & 1) value = fn(value); -/******/ return __webpack_require__.t(value, mode & ~1); -/******/ }; -/******/ return fn; -/******/ } -/******/ -/******/ // eslint-disable-next-line no-unused-vars -/******/ function hotCreateModule(moduleId) { -/******/ var hot = { -/******/ // private stuff -/******/ _acceptedDependencies: {}, -/******/ _declinedDependencies: {}, -/******/ _selfAccepted: false, -/******/ _selfDeclined: false, -/******/ _disposeHandlers: [], -/******/ _main: hotCurrentChildModule !== moduleId, -/******/ -/******/ // Module API -/******/ active: true, -/******/ accept: function(dep, callback) { -/******/ if (dep === undefined) hot._selfAccepted = true; -/******/ else if (typeof dep === "function") hot._selfAccepted = dep; -/******/ else if (typeof dep === "object") -/******/ for (var i = 0; i < dep.length; i++) -/******/ hot._acceptedDependencies[dep[i]] = callback || function() {}; -/******/ else hot._acceptedDependencies[dep] = callback || function() {}; -/******/ }, -/******/ decline: function(dep) { -/******/ if (dep === undefined) hot._selfDeclined = true; -/******/ else if (typeof dep === "object") -/******/ for (var i = 0; i < dep.length; i++) -/******/ hot._declinedDependencies[dep[i]] = true; -/******/ else hot._declinedDependencies[dep] = true; -/******/ }, -/******/ dispose: function(callback) { -/******/ hot._disposeHandlers.push(callback); -/******/ }, -/******/ addDisposeHandler: function(callback) { -/******/ hot._disposeHandlers.push(callback); -/******/ }, -/******/ removeDisposeHandler: function(callback) { -/******/ var idx = hot._disposeHandlers.indexOf(callback); -/******/ if (idx >= 0) hot._disposeHandlers.splice(idx, 1); -/******/ }, -/******/ -/******/ // Management API -/******/ check: hotCheck, -/******/ apply: hotApply, -/******/ status: function(l) { -/******/ if (!l) return hotStatus; -/******/ hotStatusHandlers.push(l); -/******/ }, -/******/ addStatusHandler: function(l) { -/******/ hotStatusHandlers.push(l); -/******/ }, -/******/ removeStatusHandler: function(l) { -/******/ var idx = hotStatusHandlers.indexOf(l); -/******/ if (idx >= 0) hotStatusHandlers.splice(idx, 1); -/******/ }, -/******/ -/******/ //inherit from previous dispose call -/******/ data: hotCurrentModuleData[moduleId] -/******/ }; -/******/ hotCurrentChildModule = undefined; -/******/ return hot; -/******/ } -/******/ -/******/ var hotStatusHandlers = []; -/******/ var hotStatus = "idle"; -/******/ -/******/ function hotSetStatus(newStatus) { -/******/ hotStatus = newStatus; -/******/ for (var i = 0; i < hotStatusHandlers.length; i++) -/******/ hotStatusHandlers[i].call(null, newStatus); -/******/ } -/******/ -/******/ // while downloading -/******/ var hotWaitingFiles = 0; -/******/ var hotChunksLoading = 0; -/******/ var hotWaitingFilesMap = {}; -/******/ var hotRequestedFilesMap = {}; -/******/ var hotAvailableFilesMap = {}; -/******/ var hotDeferred; -/******/ -/******/ // The update info -/******/ var hotUpdate, hotUpdateNewHash; -/******/ -/******/ function toModuleId(id) { -/******/ var isNumber = +id + "" === id; -/******/ return isNumber ? +id : id; -/******/ } -/******/ -/******/ function hotCheck(apply) { -/******/ if (hotStatus !== "idle") { -/******/ throw new Error("check() is only allowed in idle status"); -/******/ } -/******/ hotApplyOnUpdate = apply; -/******/ hotSetStatus("check"); -/******/ return hotDownloadManifest(hotRequestTimeout).then(function(update) { -/******/ if (!update) { -/******/ hotSetStatus("idle"); -/******/ return null; -/******/ } -/******/ hotRequestedFilesMap = {}; -/******/ hotWaitingFilesMap = {}; -/******/ hotAvailableFilesMap = update.c; -/******/ hotUpdateNewHash = update.h; -/******/ -/******/ hotSetStatus("prepare"); -/******/ var promise = new Promise(function(resolve, reject) { -/******/ hotDeferred = { -/******/ resolve: resolve, -/******/ reject: reject -/******/ }; -/******/ }); -/******/ hotUpdate = {}; -/******/ for(var chunkId in installedChunks) -/******/ // eslint-disable-next-line no-lone-blocks -/******/ { -/******/ /*globals chunkId */ -/******/ hotEnsureUpdateChunk(chunkId); -/******/ } -/******/ if ( -/******/ hotStatus === "prepare" && -/******/ hotChunksLoading === 0 && -/******/ hotWaitingFiles === 0 -/******/ ) { -/******/ hotUpdateDownloaded(); -/******/ } -/******/ return promise; -/******/ }); -/******/ } -/******/ -/******/ // eslint-disable-next-line no-unused-vars -/******/ function hotAddUpdateChunk(chunkId, moreModules) { -/******/ if (!hotAvailableFilesMap[chunkId] || !hotRequestedFilesMap[chunkId]) -/******/ return; -/******/ hotRequestedFilesMap[chunkId] = false; -/******/ for (var moduleId in moreModules) { -/******/ if (Object.prototype.hasOwnProperty.call(moreModules, moduleId)) { -/******/ hotUpdate[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if (--hotWaitingFiles === 0 && hotChunksLoading === 0) { -/******/ hotUpdateDownloaded(); -/******/ } -/******/ } -/******/ -/******/ function hotEnsureUpdateChunk(chunkId) { -/******/ if (!hotAvailableFilesMap[chunkId]) { -/******/ hotWaitingFilesMap[chunkId] = true; -/******/ } else { -/******/ hotRequestedFilesMap[chunkId] = true; -/******/ hotWaitingFiles++; -/******/ hotDownloadUpdateChunk(chunkId); -/******/ } -/******/ } -/******/ -/******/ function hotUpdateDownloaded() { -/******/ hotSetStatus("ready"); -/******/ var deferred = hotDeferred; -/******/ hotDeferred = null; -/******/ if (!deferred) return; -/******/ if (hotApplyOnUpdate) { -/******/ // Wrap deferred object in Promise to mark it as a well-handled Promise to -/******/ // avoid triggering uncaught exception warning in Chrome. -/******/ // See https://bugs.chromium.org/p/chromium/issues/detail?id=465666 -/******/ Promise.resolve() -/******/ .then(function() { -/******/ return hotApply(hotApplyOnUpdate); -/******/ }) -/******/ .then( -/******/ function(result) { -/******/ deferred.resolve(result); -/******/ }, -/******/ function(err) { -/******/ deferred.reject(err); -/******/ } -/******/ ); -/******/ } else { -/******/ var outdatedModules = []; -/******/ for (var id in hotUpdate) { -/******/ if (Object.prototype.hasOwnProperty.call(hotUpdate, id)) { -/******/ outdatedModules.push(toModuleId(id)); -/******/ } -/******/ } -/******/ deferred.resolve(outdatedModules); -/******/ } -/******/ } -/******/ -/******/ function hotApply(options) { -/******/ if (hotStatus !== "ready") -/******/ throw new Error("apply() is only allowed in ready status"); -/******/ options = options || {}; -/******/ -/******/ var cb; -/******/ var i; -/******/ var j; -/******/ var module; -/******/ var moduleId; -/******/ -/******/ function getAffectedStuff(updateModuleId) { -/******/ var outdatedModules = [updateModuleId]; -/******/ var outdatedDependencies = {}; -/******/ -/******/ var queue = outdatedModules.slice().map(function(id) { -/******/ return { -/******/ chain: [id], -/******/ id: id -/******/ }; -/******/ }); -/******/ while (queue.length > 0) { -/******/ var queueItem = queue.pop(); -/******/ var moduleId = queueItem.id; -/******/ var chain = queueItem.chain; -/******/ module = installedModules[moduleId]; -/******/ if (!module || module.hot._selfAccepted) continue; -/******/ if (module.hot._selfDeclined) { -/******/ return { -/******/ type: "self-declined", -/******/ chain: chain, -/******/ moduleId: moduleId -/******/ }; -/******/ } -/******/ if (module.hot._main) { -/******/ return { -/******/ type: "unaccepted", -/******/ chain: chain, -/******/ moduleId: moduleId -/******/ }; -/******/ } -/******/ for (var i = 0; i < module.parents.length; i++) { -/******/ var parentId = module.parents[i]; -/******/ var parent = installedModules[parentId]; -/******/ if (!parent) continue; -/******/ if (parent.hot._declinedDependencies[moduleId]) { -/******/ return { -/******/ type: "declined", -/******/ chain: chain.concat([parentId]), -/******/ moduleId: moduleId, -/******/ parentId: parentId -/******/ }; -/******/ } -/******/ if (outdatedModules.indexOf(parentId) !== -1) continue; -/******/ if (parent.hot._acceptedDependencies[moduleId]) { -/******/ if (!outdatedDependencies[parentId]) -/******/ outdatedDependencies[parentId] = []; -/******/ addAllToSet(outdatedDependencies[parentId], [moduleId]); -/******/ continue; -/******/ } -/******/ delete outdatedDependencies[parentId]; -/******/ outdatedModules.push(parentId); -/******/ queue.push({ -/******/ chain: chain.concat([parentId]), -/******/ id: parentId -/******/ }); -/******/ } -/******/ } -/******/ -/******/ return { -/******/ type: "accepted", -/******/ moduleId: updateModuleId, -/******/ outdatedModules: outdatedModules, -/******/ outdatedDependencies: outdatedDependencies -/******/ }; -/******/ } -/******/ -/******/ function addAllToSet(a, b) { -/******/ for (var i = 0; i < b.length; i++) { -/******/ var item = b[i]; -/******/ if (a.indexOf(item) === -1) a.push(item); -/******/ } -/******/ } -/******/ -/******/ // at begin all updates modules are outdated -/******/ // the "outdated" status can propagate to parents if they don't accept the children -/******/ var outdatedDependencies = {}; -/******/ var outdatedModules = []; -/******/ var appliedUpdate = {}; -/******/ -/******/ var warnUnexpectedRequire = function warnUnexpectedRequire() { -/******/ console.warn( -/******/ "[HMR] unexpected require(" + result.moduleId + ") to disposed module" -/******/ ); -/******/ }; -/******/ -/******/ for (var id in hotUpdate) { -/******/ if (Object.prototype.hasOwnProperty.call(hotUpdate, id)) { -/******/ moduleId = toModuleId(id); -/******/ /** @type {TODO} */ -/******/ var result; -/******/ if (hotUpdate[id]) { -/******/ result = getAffectedStuff(moduleId); -/******/ } else { -/******/ result = { -/******/ type: "disposed", -/******/ moduleId: id -/******/ }; -/******/ } -/******/ /** @type {Error|false} */ -/******/ var abortError = false; -/******/ var doApply = false; -/******/ var doDispose = false; -/******/ var chainInfo = ""; -/******/ if (result.chain) { -/******/ chainInfo = "\nUpdate propagation: " + result.chain.join(" -> "); -/******/ } -/******/ switch (result.type) { -/******/ case "self-declined": -/******/ if (options.onDeclined) options.onDeclined(result); -/******/ if (!options.ignoreDeclined) -/******/ abortError = new Error( -/******/ "Aborted because of self decline: " + -/******/ result.moduleId + -/******/ chainInfo -/******/ ); -/******/ break; -/******/ case "declined": -/******/ if (options.onDeclined) options.onDeclined(result); -/******/ if (!options.ignoreDeclined) -/******/ abortError = new Error( -/******/ "Aborted because of declined dependency: " + -/******/ result.moduleId + -/******/ " in " + -/******/ result.parentId + -/******/ chainInfo -/******/ ); -/******/ break; -/******/ case "unaccepted": -/******/ if (options.onUnaccepted) options.onUnaccepted(result); -/******/ if (!options.ignoreUnaccepted) -/******/ abortError = new Error( -/******/ "Aborted because " + moduleId + " is not accepted" + chainInfo -/******/ ); -/******/ break; -/******/ case "accepted": -/******/ if (options.onAccepted) options.onAccepted(result); -/******/ doApply = true; -/******/ break; -/******/ case "disposed": -/******/ if (options.onDisposed) options.onDisposed(result); -/******/ doDispose = true; -/******/ break; -/******/ default: -/******/ throw new Error("Unexception type " + result.type); -/******/ } -/******/ if (abortError) { -/******/ hotSetStatus("abort"); -/******/ return Promise.reject(abortError); -/******/ } -/******/ if (doApply) { -/******/ appliedUpdate[moduleId] = hotUpdate[moduleId]; -/******/ addAllToSet(outdatedModules, result.outdatedModules); -/******/ for (moduleId in result.outdatedDependencies) { -/******/ if ( -/******/ Object.prototype.hasOwnProperty.call( -/******/ result.outdatedDependencies, -/******/ moduleId -/******/ ) -/******/ ) { -/******/ if (!outdatedDependencies[moduleId]) -/******/ outdatedDependencies[moduleId] = []; -/******/ addAllToSet( -/******/ outdatedDependencies[moduleId], -/******/ result.outdatedDependencies[moduleId] -/******/ ); -/******/ } -/******/ } -/******/ } -/******/ if (doDispose) { -/******/ addAllToSet(outdatedModules, [result.moduleId]); -/******/ appliedUpdate[moduleId] = warnUnexpectedRequire; -/******/ } -/******/ } -/******/ } -/******/ -/******/ // Store self accepted outdated modules to require them later by the module system -/******/ var outdatedSelfAcceptedModules = []; -/******/ for (i = 0; i < outdatedModules.length; i++) { -/******/ moduleId = outdatedModules[i]; -/******/ if ( -/******/ installedModules[moduleId] && -/******/ installedModules[moduleId].hot._selfAccepted -/******/ ) -/******/ outdatedSelfAcceptedModules.push({ -/******/ module: moduleId, -/******/ errorHandler: installedModules[moduleId].hot._selfAccepted -/******/ }); -/******/ } -/******/ -/******/ // Now in "dispose" phase -/******/ hotSetStatus("dispose"); -/******/ Object.keys(hotAvailableFilesMap).forEach(function(chunkId) { -/******/ if (hotAvailableFilesMap[chunkId] === false) { -/******/ hotDisposeChunk(chunkId); -/******/ } -/******/ }); -/******/ -/******/ var idx; -/******/ var queue = outdatedModules.slice(); -/******/ while (queue.length > 0) { -/******/ moduleId = queue.pop(); -/******/ module = installedModules[moduleId]; -/******/ if (!module) continue; -/******/ -/******/ var data = {}; -/******/ -/******/ // Call dispose handlers -/******/ var disposeHandlers = module.hot._disposeHandlers; -/******/ for (j = 0; j < disposeHandlers.length; j++) { -/******/ cb = disposeHandlers[j]; -/******/ cb(data); -/******/ } -/******/ hotCurrentModuleData[moduleId] = data; -/******/ -/******/ // disable module (this disables requires from this module) -/******/ module.hot.active = false; -/******/ -/******/ // remove module from cache -/******/ delete installedModules[moduleId]; -/******/ -/******/ // when disposing there is no need to call dispose handler -/******/ delete outdatedDependencies[moduleId]; -/******/ -/******/ // remove "parents" references from all children -/******/ for (j = 0; j < module.children.length; j++) { -/******/ var child = installedModules[module.children[j]]; -/******/ if (!child) continue; -/******/ idx = child.parents.indexOf(moduleId); -/******/ if (idx >= 0) { -/******/ child.parents.splice(idx, 1); -/******/ } -/******/ } -/******/ } -/******/ -/******/ // remove outdated dependency from module children -/******/ var dependency; -/******/ var moduleOutdatedDependencies; -/******/ for (moduleId in outdatedDependencies) { -/******/ if ( -/******/ Object.prototype.hasOwnProperty.call(outdatedDependencies, moduleId) -/******/ ) { -/******/ module = installedModules[moduleId]; -/******/ if (module) { -/******/ moduleOutdatedDependencies = outdatedDependencies[moduleId]; -/******/ for (j = 0; j < moduleOutdatedDependencies.length; j++) { -/******/ dependency = moduleOutdatedDependencies[j]; -/******/ idx = module.children.indexOf(dependency); -/******/ if (idx >= 0) module.children.splice(idx, 1); -/******/ } -/******/ } -/******/ } -/******/ } -/******/ -/******/ // Not in "apply" phase -/******/ hotSetStatus("apply"); -/******/ -/******/ hotCurrentHash = hotUpdateNewHash; -/******/ -/******/ // insert new code -/******/ for (moduleId in appliedUpdate) { -/******/ if (Object.prototype.hasOwnProperty.call(appliedUpdate, moduleId)) { -/******/ modules[moduleId] = appliedUpdate[moduleId]; -/******/ } -/******/ } -/******/ -/******/ // call accept handlers -/******/ var error = null; -/******/ for (moduleId in outdatedDependencies) { -/******/ if ( -/******/ Object.prototype.hasOwnProperty.call(outdatedDependencies, moduleId) -/******/ ) { -/******/ module = installedModules[moduleId]; -/******/ if (module) { -/******/ moduleOutdatedDependencies = outdatedDependencies[moduleId]; -/******/ var callbacks = []; -/******/ for (i = 0; i < moduleOutdatedDependencies.length; i++) { -/******/ dependency = moduleOutdatedDependencies[i]; -/******/ cb = module.hot._acceptedDependencies[dependency]; -/******/ if (cb) { -/******/ if (callbacks.indexOf(cb) !== -1) continue; -/******/ callbacks.push(cb); -/******/ } -/******/ } -/******/ for (i = 0; i < callbacks.length; i++) { -/******/ cb = callbacks[i]; -/******/ try { -/******/ cb(moduleOutdatedDependencies); -/******/ } catch (err) { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "accept-errored", -/******/ moduleId: moduleId, -/******/ dependencyId: moduleOutdatedDependencies[i], -/******/ error: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ if (!error) error = err; -/******/ } -/******/ } -/******/ } -/******/ } -/******/ } -/******/ } -/******/ -/******/ // Load self accepted modules -/******/ for (i = 0; i < outdatedSelfAcceptedModules.length; i++) { -/******/ var item = outdatedSelfAcceptedModules[i]; -/******/ moduleId = item.module; -/******/ hotCurrentParents = [moduleId]; -/******/ try { -/******/ __webpack_require__(moduleId); -/******/ } catch (err) { -/******/ if (typeof item.errorHandler === "function") { -/******/ try { -/******/ item.errorHandler(err); -/******/ } catch (err2) { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "self-accept-error-handler-errored", -/******/ moduleId: moduleId, -/******/ error: err2, -/******/ originalError: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ if (!error) error = err2; -/******/ } -/******/ if (!error) error = err; -/******/ } -/******/ } else { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "self-accept-errored", -/******/ moduleId: moduleId, -/******/ error: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ if (!error) error = err; -/******/ } -/******/ } -/******/ } -/******/ } -/******/ -/******/ // handle errors in accept handlers and self accepted module load -/******/ if (error) { -/******/ hotSetStatus("fail"); -/******/ return Promise.reject(error); -/******/ } -/******/ -/******/ hotSetStatus("idle"); -/******/ return new Promise(function(resolve) { -/******/ resolve(outdatedModules); -/******/ }); -/******/ } -/******/ -/******/ // The module cache -/******/ var installedModules = {}; -/******/ -/******/ // object to store loaded and loading chunks -/******/ var installedChunks = { -/******/ "runtime": 0 -/******/ }; -/******/ -/******/ var deferredModules = []; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ -/******/ // Check if module is in cache -/******/ if(installedModules[moduleId]) { -/******/ return installedModules[moduleId].exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = installedModules[moduleId] = { -/******/ i: moduleId, -/******/ l: false, -/******/ exports: {}, -/******/ hot: hotCreateModule(moduleId), -/******/ parents: (hotCurrentParentsTemp = hotCurrentParents, hotCurrentParents = [], hotCurrentParentsTemp), -/******/ children: [] -/******/ }; -/******/ -/******/ // Execute the module function -/******/ modules[moduleId].call(module.exports, module, module.exports, hotCreateRequire(moduleId)); -/******/ -/******/ // Flag the module as loaded -/******/ module.l = true; -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = modules; -/******/ -/******/ // expose the module cache -/******/ __webpack_require__.c = installedModules; -/******/ -/******/ // define getter function for harmony exports -/******/ __webpack_require__.d = function(exports, name, getter) { -/******/ if(!__webpack_require__.o(exports, name)) { -/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); -/******/ } -/******/ }; -/******/ -/******/ // define __esModule on exports -/******/ __webpack_require__.r = function(exports) { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ -/******/ // create a fake namespace object -/******/ // mode & 1: value is a module id, require it -/******/ // mode & 2: merge all properties of value into the ns -/******/ // mode & 4: return value when already ns object -/******/ // mode & 8|1: behave like require -/******/ __webpack_require__.t = function(value, mode) { -/******/ if(mode & 1) value = __webpack_require__(value); -/******/ if(mode & 8) return value; -/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; -/******/ var ns = Object.create(null); -/******/ __webpack_require__.r(ns); -/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); -/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); -/******/ return ns; -/******/ }; -/******/ -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = function(module) { -/******/ var getter = module && module.__esModule ? -/******/ function getDefault() { return module['default']; } : -/******/ function getModuleExports() { return module; }; -/******/ __webpack_require__.d(getter, 'a', getter); -/******/ return getter; -/******/ }; -/******/ -/******/ // Object.prototype.hasOwnProperty.call -/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; -/******/ -/******/ // __webpack_public_path__ -/******/ __webpack_require__.p = ""; -/******/ -/******/ // __webpack_hash__ -/******/ __webpack_require__.h = function() { return hotCurrentHash; }; -/******/ -/******/ var jsonpArray = global["webpackJsonp"] = global["webpackJsonp"] || []; -/******/ var oldJsonpFunction = jsonpArray.push.bind(jsonpArray); -/******/ jsonpArray.push = webpackJsonpCallback; -/******/ jsonpArray = jsonpArray.slice(); -/******/ for(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]); -/******/ var parentJsonpFunction = oldJsonpFunction; -/******/ -/******/ -/******/ // run deferred modules from other chunks -/******/ checkDeferredModules(); -/******/ }) -/************************************************************************/ -/******/ ([]); -//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vd2VicGFjay9ib290c3RyYXAiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUF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tcIndlYnBhY2tKc29ucFwiXSB8fCBbXTtcbiBcdHZhciBvbGRKc29ucEZ1bmN0aW9uID0ganNvbnBBcnJheS5wdXNoLmJpbmQoanNvbnBBcnJheSk7XG4gXHRqc29ucEFycmF5LnB1c2ggPSB3ZWJwYWNrSnNvbnBDYWxsYmFjaztcbiBcdGpzb25wQXJyYXkgPSBqc29ucEFycmF5LnNsaWNlKCk7XG4gXHRmb3IodmFyIGkgPSAwOyBpIDwganNvbnBBcnJheS5sZW5ndGg7IGkrKykgd2VicGFja0pzb25wQ2FsbGJhY2soanNvbnBBcnJheVtpXSk7XG4gXHR2YXIgcGFyZW50SnNvbnBGdW5jdGlvbiA9IG9sZEpzb25wRnVuY3Rpb247XG5cblxuIFx0Ly8gcnVuIGRlZmVycmVkIG1vZHVsZXMgZnJvbSBvdGhlciBjaHVua3NcbiBcdGNoZWNrRGVmZXJyZWRNb2R1bGVzKCk7XG4iXSwic291cmNlUm9vdCI6IiJ9 \ No newline at end of file diff --git a/AppWithModules/app/tns_modules/tns-core-modules/inspector_modules.js b/AppWithModules/app/tns_modules/tns-core-modules/inspector_modules.js deleted file mode 100644 index 076db145..00000000 --- a/AppWithModules/app/tns_modules/tns-core-modules/inspector_modules.js +++ /dev/null @@ -1,12 +0,0 @@ -require("./../../runtime.js");require("./../../vendor.js");module.exports = -(global["webpackJsonp"] = global["webpackJsonp"] || []).push([["tns_modules/tns-core-modules/inspector_modules"],{ - -/***/ "./package.json": -/***/ (function(module) { - -module.exports = {"main":"main.js","android":{"v8Flags":"--expose_gc","markingMode":"none"}}; - -/***/ }) - -},[["../node_modules/tns-core-modules/inspector_modules.js","runtime","vendor"]]]); -//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsImZpbGUiOiJ0bnNfbW9kdWxlcy90bnMtY29yZS1tb2R1bGVzL2luc3BlY3Rvcl9tb2R1bGVzLmpzIiwic291cmNlUm9vdCI6IiJ9 \ No newline at end of file diff --git a/AppWithModules/app/vendor.js b/AppWithModules/app/vendor.js deleted file mode 100644 index 06e056e7..00000000 --- a/AppWithModules/app/vendor.js +++ /dev/null @@ -1,136891 +0,0 @@ -(global["webpackJsonp"] = global["webpackJsonp"] || []).push([["vendor"],{ - -/***/ "../node_modules/@angular/common/fesm5/common.js": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_c", function() { return COMMON_DIRECTIVES; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_h", function() { return NgClassImplProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_g", function() { return NgClassImplProvider__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_f", function() { return NgClassR3Impl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_k", function() { return NgStyleImplProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_j", function() { return NgStyleImplProvider__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_i", function() { return NgStyleR3Impl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_a", function() { return DEPRECATED_PLURAL_FN; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_b", function() { return getPluralCase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_e", function() { return COMMON_DEPRECATED_I18N_PIPES; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_d", function() { return COMMON_PIPES; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵregisterLocaleData", function() { return registerLocaleData; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "registerLocaleData", function() { return registerLocaleData; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatDate", function() { return formatDate; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatCurrency", function() { return formatCurrency; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatNumber", function() { return formatNumber; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatPercent", function() { return formatPercent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgLocaleLocalization", function() { return NgLocaleLocalization; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgLocalization", function() { return NgLocalization; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Plural", function() { return Plural; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NumberFormatStyle", function() { return NumberFormatStyle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormStyle", function() { return FormStyle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TranslationWidth", function() { return TranslationWidth; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormatWidth", function() { return FormatWidth; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NumberSymbol", function() { return NumberSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WeekDay", function() { return WeekDay; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getNumberOfCurrencyDigits", function() { return getNumberOfCurrencyDigits; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getCurrencySymbol", function() { return getCurrencySymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleDayPeriods", function() { return getLocaleDayPeriods; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleDayNames", function() { return getLocaleDayNames; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleMonthNames", function() { return getLocaleMonthNames; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleId", function() { return getLocaleId; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleEraNames", function() { return getLocaleEraNames; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleWeekEndRange", function() { return getLocaleWeekEndRange; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleFirstDayOfWeek", function() { return getLocaleFirstDayOfWeek; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleDateFormat", function() { return getLocaleDateFormat; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleDateTimeFormat", function() { return getLocaleDateTimeFormat; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleExtraDayPeriodRules", function() { return getLocaleExtraDayPeriodRules; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleExtraDayPeriods", function() { return getLocaleExtraDayPeriods; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocalePluralCase", function() { return getLocalePluralCase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleTimeFormat", function() { return getLocaleTimeFormat; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleNumberSymbol", function() { return getLocaleNumberSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleNumberFormat", function() { return getLocaleNumberFormat; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleCurrencyName", function() { return getLocaleCurrencyName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getLocaleCurrencySymbol", function() { return getLocaleCurrencySymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵparseCookieValue", function() { return parseCookieValue; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CommonModule", function() { return CommonModule; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeprecatedI18NPipesModule", function() { return DeprecatedI18NPipesModule; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgClass", function() { return NgClass; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgClassBase", function() { return NgClassBase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgForOf", function() { return NgForOf; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgForOfContext", function() { return NgForOfContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgIf", function() { return NgIf; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgIfContext", function() { return NgIfContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgPlural", function() { return NgPlural; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgPluralCase", function() { return NgPluralCase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgStyle", function() { return NgStyle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgStyleBase", function() { return NgStyleBase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgSwitch", function() { return NgSwitch; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgSwitchCase", function() { return NgSwitchCase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgSwitchDefault", function() { return NgSwitchDefault; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgTemplateOutlet", function() { return NgTemplateOutlet; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgComponentOutlet", function() { return NgComponentOutlet; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DOCUMENT", function() { return DOCUMENT; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AsyncPipe", function() { return AsyncPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DatePipe", function() { return DatePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "I18nPluralPipe", function() { return I18nPluralPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "I18nSelectPipe", function() { return I18nSelectPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JsonPipe", function() { return JsonPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LowerCasePipe", function() { return LowerCasePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CurrencyPipe", function() { return CurrencyPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DecimalPipe", function() { return DecimalPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PercentPipe", function() { return PercentPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SlicePipe", function() { return SlicePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UpperCasePipe", function() { return UpperCasePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TitleCasePipe", function() { return TitleCasePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "KeyValuePipe", function() { return KeyValuePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeprecatedDatePipe", function() { return DeprecatedDatePipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeprecatedCurrencyPipe", function() { return DeprecatedCurrencyPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeprecatedDecimalPipe", function() { return DeprecatedDecimalPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeprecatedPercentPipe", function() { return DeprecatedPercentPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_BROWSER_ID", function() { return PLATFORM_BROWSER_ID; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_SERVER_ID", function() { return PLATFORM_SERVER_ID; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_WORKER_APP_ID", function() { return PLATFORM_WORKER_APP_ID; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_WORKER_UI_ID", function() { return PLATFORM_WORKER_UI_ID; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isPlatformBrowser", function() { return isPlatformBrowser; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isPlatformServer", function() { return isPlatformServer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isPlatformWorkerApp", function() { return isPlatformWorkerApp; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isPlatformWorkerUi", function() { return isPlatformWorkerUi; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VERSION", function() { return VERSION; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ViewportScroller", function() { return ViewportScroller; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNullViewportScroller", function() { return NullViewportScroller; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgClassImplProvider__POST_R3__", function() { return NgClassImplProvider__POST_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgClassR2Impl", function() { return NgClassR2Impl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgClassImpl", function() { return NgClassImpl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgStyleImplProvider__POST_R3__", function() { return NgStyleImplProvider__POST_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgStyleR2Impl", function() { return NgStyleR2Impl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵNgStyleImpl", function() { return NgStyleImpl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵngStyleDirectiveDef__POST_R3__", function() { return ngStyleDirectiveDef__POST_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵngClassDirectiveDef__POST_R3__", function() { return ngClassDirectiveDef__POST_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PlatformLocation", function() { return PlatformLocation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LOCATION_INITIALIZED", function() { return LOCATION_INITIALIZED; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LocationStrategy", function() { return LocationStrategy; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "APP_BASE_HREF", function() { return APP_BASE_HREF; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HashLocationStrategy", function() { return HashLocationStrategy; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PathLocationStrategy", function() { return PathLocationStrategy; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Location", function() { return Location; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/@angular/core/fesm5/core.js"); -/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("../node_modules/tslib/tslib.es6.js"); -/** - * @license Angular v8.2.8 - * (c) 2010-2019 Google LLC. https://angular.io/ - * License: MIT - */ - - - - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * This class should not be used directly by an application developer. Instead, use - * {@link Location}. - * - * `PlatformLocation` encapsulates all calls to DOM apis, which allows the Router to be platform - * agnostic. - * This means that we can have different implementation of `PlatformLocation` for the different - * platforms that angular supports. For example, `@angular/platform-browser` provides an - * implementation specific to the browser environment, while `@angular/platform-webworker` provides - * one suitable for use with web workers. - * - * The `PlatformLocation` class is used directly by all implementations of {@link LocationStrategy} - * when they need to interact with the DOM apis like pushState, popState, etc... - * - * {@link LocationStrategy} in turn is used by the {@link Location} service which is used directly - * by the {@link Router} in order to navigate between routes. Since all interactions between {@link - * Router} / - * {@link Location} / {@link LocationStrategy} and DOM apis flow through the `PlatformLocation` - * class they are all platform independent. - * - * @publicApi - */ -var PlatformLocation = /** @class */ (function () { - function PlatformLocation() { - } - return PlatformLocation; -}()); -/** - * @description - * Indicates when a location is initialized. - * - * @publicApi - */ -var LOCATION_INITIALIZED = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('Location Initialized'); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Enables the `Location` service to read route state from the browser's URL. - * Angular provides two strategies: - * `HashLocationStrategy` and `PathLocationStrategy`. - * - * Applications should use the `Router` or `Location` services to - * interact with application route state. - * - * For instance, `HashLocationStrategy` produces URLs like - * http://example.com#/foo, - * and `PathLocationStrategy` produces - * http://example.com/foo as an equivalent URL. - * - * See these two classes for more. - * - * @publicApi - */ -var LocationStrategy = /** @class */ (function () { - function LocationStrategy() { - } - return LocationStrategy; -}()); -/** - * A predefined [DI token](guide/glossary#di-token) for the base href - * to be used with the `PathLocationStrategy`. - * The base href is the URL prefix that should be preserved when generating - * and recognizing URLs. - * - * @usageNotes - * - * The following example shows how to use this token to configure the root app injector - * with a base href value, so that the DI framework can supply the dependency anywhere in the app. - * - * ```typescript - * import {Component, NgModule} from '@angular/core'; - * import {APP_BASE_HREF} from '@angular/common'; - * - * @NgModule({ - * providers: [{provide: APP_BASE_HREF, useValue: '/my/app'}] - * }) - * class AppModule {} - * ``` - * - * @publicApi - */ -var APP_BASE_HREF = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('appBaseHref'); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @description - * - * A service that applications can use to interact with a browser's URL. - * - * Depending on the `LocationStrategy` used, `Location` persists - * to the URL's path or the URL's hash segment. - * - * @usageNotes - * - * It's better to use the `Router#navigate` service to trigger route changes. Use - * `Location` only if you need to interact with or create normalized URLs outside of - * routing. - * - * `Location` is responsible for normalizing the URL against the application's base href. - * A normalized URL is absolute from the URL host, includes the application's base href, and has no - * trailing slash: - * - `/my/app/user/123` is normalized - * - `my/app/user/123` **is not** normalized - * - `/my/app/user/123/` **is not** normalized - * - * ### Example - * - * - * - * @publicApi - */ -var Location = /** @class */ (function () { - function Location(platformStrategy, platformLocation) { - var _this = this; - /** @internal */ - this._subject = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - /** @internal */ - this._urlChangeListeners = []; - this._platformStrategy = platformStrategy; - var browserBaseHref = this._platformStrategy.getBaseHref(); - this._platformLocation = platformLocation; - this._baseHref = Location_1.stripTrailingSlash(_stripIndexHtml(browserBaseHref)); - this._platformStrategy.onPopState(function (ev) { - _this._subject.emit({ - 'url': _this.path(true), - 'pop': true, - 'state': ev.state, - 'type': ev.type, - }); - }); - } - Location_1 = Location; - /** - * Normalizes the URL path for this location. - * - * @param includeHash True to include an anchor fragment in the path. - * - * @returns The normalized URL path. - */ - // TODO: vsavkin. Remove the boolean flag and always include hash once the deprecated router is - // removed. - Location.prototype.path = function (includeHash) { - if (includeHash === void 0) { includeHash = false; } - return this.normalize(this._platformStrategy.path(includeHash)); - }; - /** - * Reports the current state of the location history. - * @returns The current value of the `history.state` object. - */ - Location.prototype.getState = function () { return this._platformLocation.getState(); }; - /** - * Normalizes the given path and compares to the current normalized path. - * - * @param path The given URL path. - * @param query Query parameters. - * - * @returns True if the given URL path is equal to the current normalized path, false - * otherwise. - */ - Location.prototype.isCurrentPathEqualTo = function (path, query) { - if (query === void 0) { query = ''; } - return this.path() == this.normalize(path + Location_1.normalizeQueryParams(query)); - }; - /** - * Normalizes a URL path by stripping any trailing slashes. - * - * @param url String representing a URL. - * - * @returns The normalized URL string. - */ - Location.prototype.normalize = function (url) { - return Location_1.stripTrailingSlash(_stripBaseHref(this._baseHref, _stripIndexHtml(url))); - }; - /** - * Normalizes an external URL path. - * If the given URL doesn't begin with a leading slash (`'/'`), adds one - * before normalizing. Adds a hash if `HashLocationStrategy` is - * in use, or the `APP_BASE_HREF` if the `PathLocationStrategy` is in use. - * - * @param url String representing a URL. - * - * @returns A normalized platform-specific URL. - */ - Location.prototype.prepareExternalUrl = function (url) { - if (url && url[0] !== '/') { - url = '/' + url; - } - return this._platformStrategy.prepareExternalUrl(url); - }; - // TODO: rename this method to pushState - /** - * Changes the browser's URL to a normalized version of a given URL, and pushes a - * new item onto the platform's history. - * - * @param path URL path to normalize. - * @param query Query parameters. - * @param state Location history state. - * - */ - Location.prototype.go = function (path, query, state) { - if (query === void 0) { query = ''; } - if (state === void 0) { state = null; } - this._platformStrategy.pushState(state, '', path, query); - this._notifyUrlChangeListeners(this.prepareExternalUrl(path + Location_1.normalizeQueryParams(query)), state); - }; - /** - * Changes the browser's URL to a normalized version of the given URL, and replaces - * the top item on the platform's history stack. - * - * @param path URL path to normalize. - * @param query Query parameters. - * @param state Location history state. - */ - Location.prototype.replaceState = function (path, query, state) { - if (query === void 0) { query = ''; } - if (state === void 0) { state = null; } - this._platformStrategy.replaceState(state, '', path, query); - this._notifyUrlChangeListeners(this.prepareExternalUrl(path + Location_1.normalizeQueryParams(query)), state); - }; - /** - * Navigates forward in the platform's history. - */ - Location.prototype.forward = function () { this._platformStrategy.forward(); }; - /** - * Navigates back in the platform's history. - */ - Location.prototype.back = function () { this._platformStrategy.back(); }; - /** - * Registers a URL change listener. Use to catch updates performed by the Angular - * framework that are not detectible through "popstate" or "hashchange" events. - * - * @param fn The change handler function, which take a URL and a location history state. - */ - Location.prototype.onUrlChange = function (fn) { - var _this = this; - this._urlChangeListeners.push(fn); - this.subscribe(function (v) { _this._notifyUrlChangeListeners(v.url, v.state); }); - }; - /** @internal */ - Location.prototype._notifyUrlChangeListeners = function (url, state) { - if (url === void 0) { url = ''; } - this._urlChangeListeners.forEach(function (fn) { return fn(url, state); }); - }; - /** - * Subscribes to the platform's `popState` events. - * - * @param value Event that is triggered when the state history changes. - * @param exception The exception to throw. - * - * @returns Subscribed events. - */ - Location.prototype.subscribe = function (onNext, onThrow, onReturn) { - return this._subject.subscribe({ next: onNext, error: onThrow, complete: onReturn }); - }; - /** - * Normalizes URL parameters by prepending with `?` if needed. - * - * @param params String of URL parameters. - * - * @returns The normalized URL parameters string. - */ - Location.normalizeQueryParams = function (params) { - return params && params[0] !== '?' ? '?' + params : params; - }; - /** - * Joins two parts of a URL with a slash if needed. - * - * @param start URL string - * @param end URL string - * - * - * @returns The joined URL string. - */ - Location.joinWithSlash = function (start, end) { - if (start.length == 0) { - return end; - } - if (end.length == 0) { - return start; - } - var slashes = 0; - if (start.endsWith('/')) { - slashes++; - } - if (end.startsWith('/')) { - slashes++; - } - if (slashes == 2) { - return start + end.substring(1); - } - if (slashes == 1) { - return start + end; - } - return start + '/' + end; - }; - /** - * Removes a trailing slash from a URL string if needed. - * Looks for the first occurrence of either `#`, `?`, or the end of the - * line as `/` characters and removes the trailing slash if one exists. - * - * @param url URL string. - * - * @returns The URL string, modified if needed. - */ - Location.stripTrailingSlash = function (url) { - var match = url.match(/#|\?|$/); - var pathEndIdx = match && match.index || url.length; - var droppedSlashIdx = pathEndIdx - (url[pathEndIdx - 1] === '/' ? 1 : 0); - return url.slice(0, droppedSlashIdx) + url.slice(pathEndIdx); - }; - var Location_1; - Location = Location_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [LocationStrategy, PlatformLocation]) - ], Location); - return Location; -}()); -function _stripBaseHref(baseHref, url) { - return baseHref && url.startsWith(baseHref) ? url.substring(baseHref.length) : url; -} -function _stripIndexHtml(url) { - return url.replace(/\/index.html$/, ''); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @description - * A {@link LocationStrategy} used to configure the {@link Location} service to - * represent its state in the - * [hash fragment](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax) - * of the browser's URL. - * - * For instance, if you call `location.go('/foo')`, the browser's URL will become - * `example.com#/foo`. - * - * @usageNotes - * - * ### Example - * - * {@example common/location/ts/hash_location_component.ts region='LocationComponent'} - * - * @publicApi - */ -var HashLocationStrategy = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__extends"])(HashLocationStrategy, _super); - function HashLocationStrategy(_platformLocation, _baseHref) { - var _this = _super.call(this) || this; - _this._platformLocation = _platformLocation; - _this._baseHref = ''; - if (_baseHref != null) { - _this._baseHref = _baseHref; - } - return _this; - } - HashLocationStrategy.prototype.onPopState = function (fn) { - this._platformLocation.onPopState(fn); - this._platformLocation.onHashChange(fn); - }; - HashLocationStrategy.prototype.getBaseHref = function () { return this._baseHref; }; - HashLocationStrategy.prototype.path = function (includeHash) { - if (includeHash === void 0) { includeHash = false; } - // the hash value is always prefixed with a `#` - // and if it is empty then it will stay empty - var path = this._platformLocation.hash; - if (path == null) - path = '#'; - return path.length > 0 ? path.substring(1) : path; - }; - HashLocationStrategy.prototype.prepareExternalUrl = function (internal) { - var url = Location.joinWithSlash(this._baseHref, internal); - return url.length > 0 ? ('#' + url) : url; - }; - HashLocationStrategy.prototype.pushState = function (state, title, path, queryParams) { - var url = this.prepareExternalUrl(path + Location.normalizeQueryParams(queryParams)); - if (url.length == 0) { - url = this._platformLocation.pathname; - } - this._platformLocation.pushState(state, title, url); - }; - HashLocationStrategy.prototype.replaceState = function (state, title, path, queryParams) { - var url = this.prepareExternalUrl(path + Location.normalizeQueryParams(queryParams)); - if (url.length == 0) { - url = this._platformLocation.pathname; - } - this._platformLocation.replaceState(state, title, url); - }; - HashLocationStrategy.prototype.forward = function () { this._platformLocation.forward(); }; - HashLocationStrategy.prototype.back = function () { this._platformLocation.back(); }; - HashLocationStrategy = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"])()), Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(APP_BASE_HREF)), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [PlatformLocation, String]) - ], HashLocationStrategy); - return HashLocationStrategy; -}(LocationStrategy)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @description - * A {@link LocationStrategy} used to configure the {@link Location} service to - * represent its state in the - * [path](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax) of the - * browser's URL. - * - * If you're using `PathLocationStrategy`, you must provide a {@link APP_BASE_HREF} - * or add a base element to the document. This URL prefix that will be preserved - * when generating and recognizing URLs. - * - * For instance, if you provide an `APP_BASE_HREF` of `'/my/app'` and call - * `location.go('/foo')`, the browser's URL will become - * `example.com/my/app/foo`. - * - * Similarly, if you add `` to the document and call - * `location.go('/foo')`, the browser's URL will become - * `example.com/my/app/foo`. - * - * @usageNotes - * - * ### Example - * - * {@example common/location/ts/path_location_component.ts region='LocationComponent'} - * - * @publicApi - */ -var PathLocationStrategy = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__extends"])(PathLocationStrategy, _super); - function PathLocationStrategy(_platformLocation, href) { - var _this = _super.call(this) || this; - _this._platformLocation = _platformLocation; - if (href == null) { - href = _this._platformLocation.getBaseHrefFromDOM(); - } - if (href == null) { - throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document."); - } - _this._baseHref = href; - return _this; - } - PathLocationStrategy.prototype.onPopState = function (fn) { - this._platformLocation.onPopState(fn); - this._platformLocation.onHashChange(fn); - }; - PathLocationStrategy.prototype.getBaseHref = function () { return this._baseHref; }; - PathLocationStrategy.prototype.prepareExternalUrl = function (internal) { - return Location.joinWithSlash(this._baseHref, internal); - }; - PathLocationStrategy.prototype.path = function (includeHash) { - if (includeHash === void 0) { includeHash = false; } - var pathname = this._platformLocation.pathname + - Location.normalizeQueryParams(this._platformLocation.search); - var hash = this._platformLocation.hash; - return hash && includeHash ? "" + pathname + hash : pathname; - }; - PathLocationStrategy.prototype.pushState = function (state, title, url, queryParams) { - var externalUrl = this.prepareExternalUrl(url + Location.normalizeQueryParams(queryParams)); - this._platformLocation.pushState(state, title, externalUrl); - }; - PathLocationStrategy.prototype.replaceState = function (state, title, url, queryParams) { - var externalUrl = this.prepareExternalUrl(url + Location.normalizeQueryParams(queryParams)); - this._platformLocation.replaceState(state, title, externalUrl); - }; - PathLocationStrategy.prototype.forward = function () { this._platformLocation.forward(); }; - PathLocationStrategy.prototype.back = function () { this._platformLocation.back(); }; - PathLocationStrategy = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"])()), Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(APP_BASE_HREF)), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [PlatformLocation, String]) - ], PathLocationStrategy); - return PathLocationStrategy; -}(LocationStrategy)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** @internal */ -var CURRENCIES_EN = { - 'ADP': [undefined, undefined, 0], - 'AFN': [undefined, undefined, 0], - 'ALL': [undefined, undefined, 0], - 'AMD': [undefined, undefined, 0], - 'AOA': [undefined, 'Kz'], - 'ARS': [undefined, '$'], - 'AUD': ['A$', '$'], - 'BAM': [undefined, 'KM'], - 'BBD': [undefined, '$'], - 'BDT': [undefined, '৳'], - 'BHD': [undefined, undefined, 3], - 'BIF': [undefined, undefined, 0], - 'BMD': [undefined, '$'], - 'BND': [undefined, '$'], - 'BOB': [undefined, 'Bs'], - 'BRL': ['R$'], - 'BSD': [undefined, '$'], - 'BWP': [undefined, 'P'], - 'BYN': [undefined, 'р.', 2], - 'BYR': [undefined, undefined, 0], - 'BZD': [undefined, '$'], - 'CAD': ['CA$', '$', 2], - 'CHF': [undefined, undefined, 2], - 'CLF': [undefined, undefined, 4], - 'CLP': [undefined, '$', 0], - 'CNY': ['CN¥', '¥'], - 'COP': [undefined, '$', 0], - 'CRC': [undefined, '₡', 2], - 'CUC': [undefined, '$'], - 'CUP': [undefined, '$'], - 'CZK': [undefined, 'Kč', 2], - 'DJF': [undefined, undefined, 0], - 'DKK': [undefined, 'kr', 2], - 'DOP': [undefined, '$'], - 'EGP': [undefined, 'E£'], - 'ESP': [undefined, '₧', 0], - 'EUR': ['€'], - 'FJD': [undefined, '$'], - 'FKP': [undefined, '£'], - 'GBP': ['£'], - 'GEL': [undefined, '₾'], - 'GIP': [undefined, '£'], - 'GNF': [undefined, 'FG', 0], - 'GTQ': [undefined, 'Q'], - 'GYD': [undefined, '$', 0], - 'HKD': ['HK$', '$'], - 'HNL': [undefined, 'L'], - 'HRK': [undefined, 'kn'], - 'HUF': [undefined, 'Ft', 2], - 'IDR': [undefined, 'Rp', 0], - 'ILS': ['₪'], - 'INR': ['₹'], - 'IQD': [undefined, undefined, 0], - 'IRR': [undefined, undefined, 0], - 'ISK': [undefined, 'kr', 0], - 'ITL': [undefined, undefined, 0], - 'JMD': [undefined, '$'], - 'JOD': [undefined, undefined, 3], - 'JPY': ['¥', undefined, 0], - 'KHR': [undefined, '៛'], - 'KMF': [undefined, 'CF', 0], - 'KPW': [undefined, '₩', 0], - 'KRW': ['₩', undefined, 0], - 'KWD': [undefined, undefined, 3], - 'KYD': [undefined, '$'], - 'KZT': [undefined, '₸'], - 'LAK': [undefined, '₭', 0], - 'LBP': [undefined, 'L£', 0], - 'LKR': [undefined, 'Rs'], - 'LRD': [undefined, '$'], - 'LTL': [undefined, 'Lt'], - 'LUF': [undefined, undefined, 0], - 'LVL': [undefined, 'Ls'], - 'LYD': [undefined, undefined, 3], - 'MGA': [undefined, 'Ar', 0], - 'MGF': [undefined, undefined, 0], - 'MMK': [undefined, 'K', 0], - 'MNT': [undefined, '₮', 0], - 'MRO': [undefined, undefined, 0], - 'MUR': [undefined, 'Rs', 0], - 'MXN': ['MX$', '$'], - 'MYR': [undefined, 'RM'], - 'NAD': [undefined, '$'], - 'NGN': [undefined, '₦'], - 'NIO': [undefined, 'C$'], - 'NOK': [undefined, 'kr', 2], - 'NPR': [undefined, 'Rs'], - 'NZD': ['NZ$', '$'], - 'OMR': [undefined, undefined, 3], - 'PHP': [undefined, '₱'], - 'PKR': [undefined, 'Rs', 0], - 'PLN': [undefined, 'zł'], - 'PYG': [undefined, '₲', 0], - 'RON': [undefined, 'lei'], - 'RSD': [undefined, undefined, 0], - 'RUB': [undefined, '₽'], - 'RUR': [undefined, 'р.'], - 'RWF': [undefined, 'RF', 0], - 'SBD': [undefined, '$'], - 'SEK': [undefined, 'kr', 2], - 'SGD': [undefined, '$'], - 'SHP': [undefined, '£'], - 'SLL': [undefined, undefined, 0], - 'SOS': [undefined, undefined, 0], - 'SRD': [undefined, '$'], - 'SSP': [undefined, '£'], - 'STD': [undefined, undefined, 0], - 'STN': [undefined, 'Db'], - 'SYP': [undefined, '£', 0], - 'THB': [undefined, '฿'], - 'TMM': [undefined, undefined, 0], - 'TND': [undefined, undefined, 3], - 'TOP': [undefined, 'T$'], - 'TRL': [undefined, undefined, 0], - 'TRY': [undefined, '₺'], - 'TTD': [undefined, '$'], - 'TWD': ['NT$', '$', 2], - 'TZS': [undefined, undefined, 0], - 'UAH': [undefined, '₴'], - 'UGX': [undefined, undefined, 0], - 'USD': ['$'], - 'UYI': [undefined, undefined, 0], - 'UYU': [undefined, '$'], - 'UZS': [undefined, undefined, 0], - 'VEF': [undefined, 'Bs'], - 'VND': ['₫', undefined, 0], - 'VUV': [undefined, undefined, 0], - 'XAF': ['FCFA', undefined, 0], - 'XCD': ['EC$', '$'], - 'XOF': ['CFA', undefined, 0], - 'XPF': ['CFPF', undefined, 0], - 'YER': [undefined, undefined, 0], - 'ZAR': [undefined, 'R'], - 'ZMK': [undefined, undefined, 0], - 'ZMW': [undefined, 'ZK'], - 'ZWD': [undefined, undefined, 0] -}; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Format styles that can be used to represent numbers. - * @see `getLocaleNumberFormat()`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -var NumberFormatStyle; -(function (NumberFormatStyle) { - NumberFormatStyle[NumberFormatStyle["Decimal"] = 0] = "Decimal"; - NumberFormatStyle[NumberFormatStyle["Percent"] = 1] = "Percent"; - NumberFormatStyle[NumberFormatStyle["Currency"] = 2] = "Currency"; - NumberFormatStyle[NumberFormatStyle["Scientific"] = 3] = "Scientific"; -})(NumberFormatStyle || (NumberFormatStyle = {})); -/** - * Plurality cases used for translating plurals to different languages. - * - * @see `NgPlural` - * @see `NgPluralCase` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -var Plural; -(function (Plural) { - Plural[Plural["Zero"] = 0] = "Zero"; - Plural[Plural["One"] = 1] = "One"; - Plural[Plural["Two"] = 2] = "Two"; - Plural[Plural["Few"] = 3] = "Few"; - Plural[Plural["Many"] = 4] = "Many"; - Plural[Plural["Other"] = 5] = "Other"; -})(Plural || (Plural = {})); -/** - * Context-dependant translation forms for strings. - * Typically the standalone version is for the nominative form of the word, - * and the format version is used for the genitive case. - * @see [CLDR website](http://cldr.unicode.org/translation/date-time#TOC-Stand-Alone-vs.-Format-Styles) - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -var FormStyle; -(function (FormStyle) { - FormStyle[FormStyle["Format"] = 0] = "Format"; - FormStyle[FormStyle["Standalone"] = 1] = "Standalone"; -})(FormStyle || (FormStyle = {})); -/** - * String widths available for translations. - * The specific character widths are locale-specific. - * Examples are given for the word "Sunday" in English. - * - * @publicApi - */ -var TranslationWidth; -(function (TranslationWidth) { - /** 1 character for `en-US`. For example: 'S' */ - TranslationWidth[TranslationWidth["Narrow"] = 0] = "Narrow"; - /** 3 characters for `en-US`. For example: 'Sun' */ - TranslationWidth[TranslationWidth["Abbreviated"] = 1] = "Abbreviated"; - /** Full length for `en-US`. For example: "Sunday" */ - TranslationWidth[TranslationWidth["Wide"] = 2] = "Wide"; - /** 2 characters for `en-US`, For example: "Su" */ - TranslationWidth[TranslationWidth["Short"] = 3] = "Short"; -})(TranslationWidth || (TranslationWidth = {})); -/** - * String widths available for date-time formats. - * The specific character widths are locale-specific. - * Examples are given for `en-US`. - * - * @see `getLocaleDateFormat()` - * @see `getLocaleTimeFormat()`` - * @see `getLocaleDateTimeFormat()` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * @publicApi - */ -var FormatWidth; -(function (FormatWidth) { - /** - * For `en-US`, 'M/d/yy, h:mm a'` - * (Example: `6/15/15, 9:03 AM`) - */ - FormatWidth[FormatWidth["Short"] = 0] = "Short"; - /** - * For `en-US`, `'MMM d, y, h:mm:ss a'` - * (Example: `Jun 15, 2015, 9:03:01 AM`) - */ - FormatWidth[FormatWidth["Medium"] = 1] = "Medium"; - /** - * For `en-US`, `'MMMM d, y, h:mm:ss a z'` - * (Example: `June 15, 2015 at 9:03:01 AM GMT+1`) - */ - FormatWidth[FormatWidth["Long"] = 2] = "Long"; - /** - * For `en-US`, `'EEEE, MMMM d, y, h:mm:ss a zzzz'` - * (Example: `Monday, June 15, 2015 at 9:03:01 AM GMT+01:00`) - */ - FormatWidth[FormatWidth["Full"] = 3] = "Full"; -})(FormatWidth || (FormatWidth = {})); -/** - * Symbols that can be used to replace placeholders in number patterns. - * Examples are based on `en-US` values. - * - * @see `getLocaleNumberSymbol()` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -var NumberSymbol; -(function (NumberSymbol) { - /** - * Decimal separator. - * For `en-US`, the dot character. - * Example : 2,345`.`67 - */ - NumberSymbol[NumberSymbol["Decimal"] = 0] = "Decimal"; - /** - * Grouping separator, typically for thousands. - * For `en-US`, the comma character. - * Example: 2`,`345.67 - */ - NumberSymbol[NumberSymbol["Group"] = 1] = "Group"; - /** - * List-item separator. - * Example: "one, two, and three" - */ - NumberSymbol[NumberSymbol["List"] = 2] = "List"; - /** - * Sign for percentage (out of 100). - * Example: 23.4% - */ - NumberSymbol[NumberSymbol["PercentSign"] = 3] = "PercentSign"; - /** - * Sign for positive numbers. - * Example: +23 - */ - NumberSymbol[NumberSymbol["PlusSign"] = 4] = "PlusSign"; - /** - * Sign for negative numbers. - * Example: -23 - */ - NumberSymbol[NumberSymbol["MinusSign"] = 5] = "MinusSign"; - /** - * Computer notation for exponential value (n times a power of 10). - * Example: 1.2E3 - */ - NumberSymbol[NumberSymbol["Exponential"] = 6] = "Exponential"; - /** - * Human-readable format of exponential. - * Example: 1.2x103 - */ - NumberSymbol[NumberSymbol["SuperscriptingExponent"] = 7] = "SuperscriptingExponent"; - /** - * Sign for permille (out of 1000). - * Example: 23.4‰ - */ - NumberSymbol[NumberSymbol["PerMille"] = 8] = "PerMille"; - /** - * Infinity, can be used with plus and minus. - * Example: ∞, +∞, -∞ - */ - NumberSymbol[NumberSymbol["Infinity"] = 9] = "Infinity"; - /** - * Not a number. - * Example: NaN - */ - NumberSymbol[NumberSymbol["NaN"] = 10] = "NaN"; - /** - * Symbol used between time units. - * Example: 10:52 - */ - NumberSymbol[NumberSymbol["TimeSeparator"] = 11] = "TimeSeparator"; - /** - * Decimal separator for currency values (fallback to `Decimal`). - * Example: $2,345.67 - */ - NumberSymbol[NumberSymbol["CurrencyDecimal"] = 12] = "CurrencyDecimal"; - /** - * Group separator for currency values (fallback to `Group`). - * Example: $2,345.67 - */ - NumberSymbol[NumberSymbol["CurrencyGroup"] = 13] = "CurrencyGroup"; -})(NumberSymbol || (NumberSymbol = {})); -/** - * The value for each day of the week, based on the `en-US` locale - * - * @publicApi - */ -var WeekDay; -(function (WeekDay) { - WeekDay[WeekDay["Sunday"] = 0] = "Sunday"; - WeekDay[WeekDay["Monday"] = 1] = "Monday"; - WeekDay[WeekDay["Tuesday"] = 2] = "Tuesday"; - WeekDay[WeekDay["Wednesday"] = 3] = "Wednesday"; - WeekDay[WeekDay["Thursday"] = 4] = "Thursday"; - WeekDay[WeekDay["Friday"] = 5] = "Friday"; - WeekDay[WeekDay["Saturday"] = 6] = "Saturday"; -})(WeekDay || (WeekDay = {})); -/** - * Retrieves the locale ID from the currently loaded locale. - * The loaded locale could be, for example, a global one rather than a regional one. - * @param locale A locale code, such as `fr-FR`. - * @returns The locale code. For example, `fr`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleId(locale) { - return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale)[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].LocaleId]; -} -/** - * Retrieves day period strings for the given locale. - * - * @param locale A locale code for the locale format rules to use. - * @param formStyle The required grammatical form. - * @param width The required character width. - * @returns An array of localized period strings. For example, `[AM, PM]` for `en-US`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleDayPeriods(locale, formStyle, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var amPmData = [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DayPeriodsFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DayPeriodsStandalone]]; - var amPm = getLastDefinedValue(amPmData, formStyle); - return getLastDefinedValue(amPm, width); -} -/** - * Retrieves days of the week for the given locale, using the Gregorian calendar. - * - * @param locale A locale code for the locale format rules to use. - * @param formStyle The required grammatical form. - * @param width The required character width. - * @returns An array of localized name strings. - * For example,`[Sunday, Monday, ... Saturday]` for `en-US`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleDayNames(locale, formStyle, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var daysData = [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DaysFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DaysStandalone]]; - var days = getLastDefinedValue(daysData, formStyle); - return getLastDefinedValue(days, width); -} -/** - * Retrieves months of the year for the given locale, using the Gregorian calendar. - * - * @param locale A locale code for the locale format rules to use. - * @param formStyle The required grammatical form. - * @param width The required character width. - * @returns An array of localized name strings. - * For example, `[January, February, ...]` for `en-US`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleMonthNames(locale, formStyle, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var monthsData = [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].MonthsFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].MonthsStandalone]]; - var months = getLastDefinedValue(monthsData, formStyle); - return getLastDefinedValue(months, width); -} -/** - * Retrieves Gregorian-calendar eras for the given locale. - * @param locale A locale code for the locale format rules to use. - * @param formStyle The required grammatical form. - * @param width The required character width. - - * @returns An array of localized era strings. - * For example, `[AD, BC]` for `en-US`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleEraNames(locale, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var erasData = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].Eras]; - return getLastDefinedValue(erasData, width); -} -/** - * Retrieves the first day of the week for the given locale. - * - * @param locale A locale code for the locale format rules to use. - * @returns A day index number, using the 0-based week-day index for `en-US` - * (Sunday = 0, Monday = 1, ...). - * For example, for `fr-FR`, returns 1 to indicate that the first day is Monday. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleFirstDayOfWeek(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].FirstDayOfWeek]; -} -/** - * Range of week days that are considered the week-end for the given locale. - * - * @param locale A locale code for the locale format rules to use. - * @returns The range of day values, `[startDay, endDay]`. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleWeekEndRange(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].WeekendRange]; -} -/** - * Retrieves a localized date-value formating string. - * - * @param locale A locale code for the locale format rules to use. - * @param width The format type. - * @returns The localized formating string. - * @see `FormatWidth` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleDateFormat(locale, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return getLastDefinedValue(data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DateFormat], width); -} -/** - * Retrieves a localized time-value formatting string. - * - * @param locale A locale code for the locale format rules to use. - * @param width The format type. - * @returns The localized formatting string. - * @see `FormatWidth` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - - * @publicApi - */ -function getLocaleTimeFormat(locale, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return getLastDefinedValue(data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].TimeFormat], width); -} -/** - * Retrieves a localized date-time formatting string. - * - * @param locale A locale code for the locale format rules to use. - * @param width The format type. - * @returns The localized formatting string. - * @see `FormatWidth` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleDateTimeFormat(locale, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var dateTimeFormatData = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DateTimeFormat]; - return getLastDefinedValue(dateTimeFormatData, width); -} -/** - * Retrieves a localized number symbol that can be used to replace placeholders in number formats. - * @param locale The locale code. - * @param symbol The symbol to localize. - * @returns The character for the localized symbol. - * @see `NumberSymbol` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleNumberSymbol(locale, symbol) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - var res = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][symbol]; - if (typeof res === 'undefined') { - if (symbol === NumberSymbol.CurrencyDecimal) { - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][NumberSymbol.Decimal]; - } - else if (symbol === NumberSymbol.CurrencyGroup) { - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][NumberSymbol.Group]; - } - } - return res; -} -/** - * Retrieves a number format for a given locale. - * - * Numbers are formatted using patterns, like `#,###.00`. For example, the pattern `#,###.00` - * when used to format the number 12345.678 could result in "12'345,678". That would happen if the - * grouping separator for your language is an apostrophe, and the decimal separator is a comma. - * - * Important: The characters `.` `,` `0` `#` (and others below) are special placeholders - * that stand for the decimal separator, and so on, and are NOT real characters. - * You must NOT "translate" the placeholders. For example, don't change `.` to `,` even though in - * your language the decimal point is written with a comma. The symbols should be replaced by the - * local equivalents, using the appropriate `NumberSymbol` for your language. - * - * Here are the special characters used in number patterns: - * - * | Symbol | Meaning | - * |--------|---------| - * | . | Replaced automatically by the character used for the decimal point. | - * | , | Replaced by the "grouping" (thousands) separator. | - * | 0 | Replaced by a digit (or zero if there aren't enough digits). | - * | # | Replaced by a digit (or nothing if there aren't enough). | - * | ¤ | Replaced by a currency symbol, such as $ or USD. | - * | % | Marks a percent format. The % symbol may change position, but must be retained. | - * | E | Marks a scientific format. The E symbol may change position, but must be retained. | - * | ' | Special characters used as literal characters are quoted with ASCII single quotes. | - * - * @param locale A locale code for the locale format rules to use. - * @param type The type of numeric value to be formatted (such as `Decimal` or `Currency`.) - * @returns The localized format string. - * @see `NumberFormatStyle` - * @see [CLDR website](http://cldr.unicode.org/translation/number-patterns) - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleNumberFormat(locale, type) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberFormats][type]; -} -/** - * Retrieves the symbol used to represent the currency for the main country - * corresponding to a given locale. For example, '$' for `en-US`. - * - * @param locale A locale code for the locale format rules to use. - * @returns The localized symbol character, - * or `null` if the main country cannot be determined. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleCurrencySymbol(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].CurrencySymbol] || null; -} -/** - * Retrieves the name of the currency for the main country corresponding - * to a given locale. For example, 'US Dollar' for `en-US`. - * @param locale A locale code for the locale format rules to use. - * @returns The currency name, - * or `null` if the main country cannot be determined. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleCurrencyName(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].CurrencyName] || null; -} -/** - * Retrieves the currency values for a given locale. - * @param locale A locale code for the locale format rules to use. - * @returns The currency values. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - */ -function getLocaleCurrencies(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].Currencies]; -} -/** - * @alias core/ɵgetLocalePluralCase - * @publicApi - */ -var getLocalePluralCase = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵgetLocalePluralCase"]; -function checkFullData(data) { - if (!data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData]) { - throw new Error("Missing extra locale data for the locale \"" + data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].LocaleId] + "\". Use \"registerLocaleData\" to load new data. See the \"I18n guide\" on angular.io to know more."); - } -} -/** - * Retrieves locale-specific rules used to determine which day period to use - * when more than one period is defined for a locale. - * - * There is a rule for each defined day period. The - * first rule is applied to the first day period and so on. - * Fall back to AM/PM when no rules are available. - * - * A rule can specify a period as time range, or as a single time value. - * - * This functionality is only available when you have loaded the full locale data. - * See the ["I18n guide"](guide/i18n#i18n-pipes). - * - * @param locale A locale code for the locale format rules to use. - * @returns The rules for the locale, a single time value or array of *from-time, to-time*, - * or null if no periods are available. - * - * @see `getLocaleExtraDayPeriods()` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleExtraDayPeriodRules(locale) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - checkFullData(data); - var rules = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][2 /* ExtraDayPeriodsRules */] || []; - return rules.map(function (rule) { - if (typeof rule === 'string') { - return extractTime(rule); - } - return [extractTime(rule[0]), extractTime(rule[1])]; - }); -} -/** - * Retrieves locale-specific day periods, which indicate roughly how a day is broken up - * in different languages. - * For example, for `en-US`, periods are morning, noon, afternoon, evening, and midnight. - * - * This functionality is only available when you have loaded the full locale data. - * See the ["I18n guide"](guide/i18n#i18n-pipes). - * - * @param locale A locale code for the locale format rules to use. - * @param formStyle The required grammatical form. - * @param width The required character width. - * @returns The translated day-period strings. - * @see `getLocaleExtraDayPeriodRules()` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLocaleExtraDayPeriods(locale, formStyle, width) { - var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale); - checkFullData(data); - var dayPeriodsData = [ - data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][0 /* ExtraDayPeriodFormats */], - data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][1 /* ExtraDayPeriodStandalone */] - ]; - var dayPeriods = getLastDefinedValue(dayPeriodsData, formStyle) || []; - return getLastDefinedValue(dayPeriods, width) || []; -} -/** - * Retrieves the first value that is defined in an array, going backwards from an index position. - * - * To avoid repeating the same data (as when the "format" and "standalone" forms are the same) - * add the first value to the locale data arrays, and add other values only if they are different. - * - * @param data The data array to retrieve from. - * @param index A 0-based index into the array to start from. - * @returns The value immediately before the given index position. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getLastDefinedValue(data, index) { - for (var i = index; i > -1; i--) { - if (typeof data[i] !== 'undefined') { - return data[i]; - } - } - throw new Error('Locale data API: locale data undefined'); -} -/** - * Extracts the hours and minutes from a string like "15:45" - */ -function extractTime(time) { - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__read"])(time.split(':'), 2), h = _a[0], m = _a[1]; - return { hours: +h, minutes: +m }; -} -/** - * Retrieves the currency symbol for a given currency code. - * - * For example, for the default `en-US` locale, the code `USD` can - * be represented by the narrow symbol `$` or the wide symbol `US$`. - * - * @param code The currency code. - * @param format The format, `wide` or `narrow`. - * @param locale A locale code for the locale format rules to use. - * - * @returns The symbol, or the currency code if no symbol is available.0 - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getCurrencySymbol(code, format, locale) { - if (locale === void 0) { locale = 'en'; } - var currency = getLocaleCurrencies(locale)[code] || CURRENCIES_EN[code] || []; - var symbolNarrow = currency[1 /* SymbolNarrow */]; - if (format === 'narrow' && typeof symbolNarrow === 'string') { - return symbolNarrow; - } - return currency[0 /* Symbol */] || code; -} -// Most currencies have cents, that's why the default is 2 -var DEFAULT_NB_OF_CURRENCY_DIGITS = 2; -/** - * Reports the number of decimal digits for a given currency. - * The value depends upon the presence of cents in that particular currency. - * - * @param code The currency code. - * @returns The number of decimal digits, typically 0 or 2. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function getNumberOfCurrencyDigits(code) { - var digits; - var currency = CURRENCIES_EN[code]; - if (currency) { - digits = currency[2 /* NbOfDigits */]; - } - return typeof digits === 'number' ? digits : DEFAULT_NB_OF_CURRENCY_DIGITS; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var ISO8601_DATE_REGEX = /^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/; -// 1 2 3 4 5 6 7 8 9 10 11 -var NAMED_FORMATS = {}; -var DATE_FORMATS_SPLIT = /((?:[^GyMLwWdEabBhHmsSzZO']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/; -var ZoneWidth; -(function (ZoneWidth) { - ZoneWidth[ZoneWidth["Short"] = 0] = "Short"; - ZoneWidth[ZoneWidth["ShortGMT"] = 1] = "ShortGMT"; - ZoneWidth[ZoneWidth["Long"] = 2] = "Long"; - ZoneWidth[ZoneWidth["Extended"] = 3] = "Extended"; -})(ZoneWidth || (ZoneWidth = {})); -var DateType; -(function (DateType) { - DateType[DateType["FullYear"] = 0] = "FullYear"; - DateType[DateType["Month"] = 1] = "Month"; - DateType[DateType["Date"] = 2] = "Date"; - DateType[DateType["Hours"] = 3] = "Hours"; - DateType[DateType["Minutes"] = 4] = "Minutes"; - DateType[DateType["Seconds"] = 5] = "Seconds"; - DateType[DateType["FractionalSeconds"] = 6] = "FractionalSeconds"; - DateType[DateType["Day"] = 7] = "Day"; -})(DateType || (DateType = {})); -var TranslationType; -(function (TranslationType) { - TranslationType[TranslationType["DayPeriods"] = 0] = "DayPeriods"; - TranslationType[TranslationType["Days"] = 1] = "Days"; - TranslationType[TranslationType["Months"] = 2] = "Months"; - TranslationType[TranslationType["Eras"] = 3] = "Eras"; -})(TranslationType || (TranslationType = {})); -/** - * @ngModule CommonModule - * @description - * - * Formats a date according to locale rules. - * - * @param value The date to format, as a Date, or a number (milliseconds since UTC epoch) - * or an [ISO date-time string](https://www.w3.org/TR/NOTE-datetime). - * @param format The date-time components to include. See `DatePipe` for details. - * @param locale A locale code for the locale format rules to use. - * @param timezone The time zone. A time zone offset from GMT (such as `'+0430'`), - * or a standard UTC/GMT or continental US time zone abbreviation. - * If not specified, uses host system settings. - * - * @returns The formatted date string. - * - * @see `DatePipe` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function formatDate(value, format, locale, timezone) { - var date = toDate(value); - var namedFormat = getNamedFormat(locale, format); - format = namedFormat || format; - var parts = []; - var match; - while (format) { - match = DATE_FORMATS_SPLIT.exec(format); - if (match) { - parts = parts.concat(match.slice(1)); - var part = parts.pop(); - if (!part) { - break; - } - format = part; - } - else { - parts.push(format); - break; - } - } - var dateTimezoneOffset = date.getTimezoneOffset(); - if (timezone) { - dateTimezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset); - date = convertTimezoneToLocal(date, timezone, true); - } - var text = ''; - parts.forEach(function (value) { - var dateFormatter = getDateFormatter(value); - text += dateFormatter ? - dateFormatter(date, locale, dateTimezoneOffset) : - value === '\'\'' ? '\'' : value.replace(/(^'|'$)/g, '').replace(/''/g, '\''); - }); - return text; -} -function getNamedFormat(locale, format) { - var localeId = getLocaleId(locale); - NAMED_FORMATS[localeId] = NAMED_FORMATS[localeId] || {}; - if (NAMED_FORMATS[localeId][format]) { - return NAMED_FORMATS[localeId][format]; - } - var formatValue = ''; - switch (format) { - case 'shortDate': - formatValue = getLocaleDateFormat(locale, FormatWidth.Short); - break; - case 'mediumDate': - formatValue = getLocaleDateFormat(locale, FormatWidth.Medium); - break; - case 'longDate': - formatValue = getLocaleDateFormat(locale, FormatWidth.Long); - break; - case 'fullDate': - formatValue = getLocaleDateFormat(locale, FormatWidth.Full); - break; - case 'shortTime': - formatValue = getLocaleTimeFormat(locale, FormatWidth.Short); - break; - case 'mediumTime': - formatValue = getLocaleTimeFormat(locale, FormatWidth.Medium); - break; - case 'longTime': - formatValue = getLocaleTimeFormat(locale, FormatWidth.Long); - break; - case 'fullTime': - formatValue = getLocaleTimeFormat(locale, FormatWidth.Full); - break; - case 'short': - var shortTime = getNamedFormat(locale, 'shortTime'); - var shortDate = getNamedFormat(locale, 'shortDate'); - formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Short), [shortTime, shortDate]); - break; - case 'medium': - var mediumTime = getNamedFormat(locale, 'mediumTime'); - var mediumDate = getNamedFormat(locale, 'mediumDate'); - formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Medium), [mediumTime, mediumDate]); - break; - case 'long': - var longTime = getNamedFormat(locale, 'longTime'); - var longDate = getNamedFormat(locale, 'longDate'); - formatValue = - formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Long), [longTime, longDate]); - break; - case 'full': - var fullTime = getNamedFormat(locale, 'fullTime'); - var fullDate = getNamedFormat(locale, 'fullDate'); - formatValue = - formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Full), [fullTime, fullDate]); - break; - } - if (formatValue) { - NAMED_FORMATS[localeId][format] = formatValue; - } - return formatValue; -} -function formatDateTime(str, opt_values) { - if (opt_values) { - str = str.replace(/\{([^}]+)}/g, function (match, key) { - return (opt_values != null && key in opt_values) ? opt_values[key] : match; - }); - } - return str; -} -function padNumber(num, digits, minusSign, trim, negWrap) { - if (minusSign === void 0) { minusSign = '-'; } - var neg = ''; - if (num < 0 || (negWrap && num <= 0)) { - if (negWrap) { - num = -num + 1; - } - else { - num = -num; - neg = minusSign; - } - } - var strNum = String(num); - while (strNum.length < digits) { - strNum = '0' + strNum; - } - if (trim) { - strNum = strNum.substr(strNum.length - digits); - } - return neg + strNum; -} -function formatFractionalSeconds(milliseconds, digits) { - var strMs = padNumber(milliseconds, 3); - return strMs.substr(0, digits); -} -/** - * Returns a date formatter that transforms a date into its locale digit representation - */ -function dateGetter(name, size, offset, trim, negWrap) { - if (offset === void 0) { offset = 0; } - if (trim === void 0) { trim = false; } - if (negWrap === void 0) { negWrap = false; } - return function (date, locale) { - var part = getDatePart(name, date); - if (offset > 0 || part > -offset) { - part += offset; - } - if (name === DateType.Hours) { - if (part === 0 && offset === -12) { - part = 12; - } - } - else if (name === DateType.FractionalSeconds) { - return formatFractionalSeconds(part, size); - } - var localeMinus = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign); - return padNumber(part, size, localeMinus, trim, negWrap); - }; -} -function getDatePart(part, date) { - switch (part) { - case DateType.FullYear: - return date.getFullYear(); - case DateType.Month: - return date.getMonth(); - case DateType.Date: - return date.getDate(); - case DateType.Hours: - return date.getHours(); - case DateType.Minutes: - return date.getMinutes(); - case DateType.Seconds: - return date.getSeconds(); - case DateType.FractionalSeconds: - return date.getMilliseconds(); - case DateType.Day: - return date.getDay(); - default: - throw new Error("Unknown DateType value \"" + part + "\"."); - } -} -/** - * Returns a date formatter that transforms a date into its locale string representation - */ -function dateStrGetter(name, width, form, extended) { - if (form === void 0) { form = FormStyle.Format; } - if (extended === void 0) { extended = false; } - return function (date, locale) { - return getDateTranslation(date, locale, name, width, form, extended); - }; -} -/** - * Returns the locale translation of a date for a given form, type and width - */ -function getDateTranslation(date, locale, name, width, form, extended) { - switch (name) { - case TranslationType.Months: - return getLocaleMonthNames(locale, form, width)[date.getMonth()]; - case TranslationType.Days: - return getLocaleDayNames(locale, form, width)[date.getDay()]; - case TranslationType.DayPeriods: - var currentHours_1 = date.getHours(); - var currentMinutes_1 = date.getMinutes(); - if (extended) { - var rules = getLocaleExtraDayPeriodRules(locale); - var dayPeriods_1 = getLocaleExtraDayPeriods(locale, form, width); - var result_1; - rules.forEach(function (rule, index) { - if (Array.isArray(rule)) { - // morning, afternoon, evening, night - var _a = rule[0], hoursFrom = _a.hours, minutesFrom = _a.minutes; - var _b = rule[1], hoursTo = _b.hours, minutesTo = _b.minutes; - if (currentHours_1 >= hoursFrom && currentMinutes_1 >= minutesFrom && - (currentHours_1 < hoursTo || - (currentHours_1 === hoursTo && currentMinutes_1 < minutesTo))) { - result_1 = dayPeriods_1[index]; - } - } - else { // noon or midnight - var hours = rule.hours, minutes = rule.minutes; - if (hours === currentHours_1 && minutes === currentMinutes_1) { - result_1 = dayPeriods_1[index]; - } - } - }); - if (result_1) { - return result_1; - } - } - // if no rules for the day periods, we use am/pm by default - return getLocaleDayPeriods(locale, form, width)[currentHours_1 < 12 ? 0 : 1]; - case TranslationType.Eras: - return getLocaleEraNames(locale, width)[date.getFullYear() <= 0 ? 0 : 1]; - default: - // This default case is not needed by TypeScript compiler, as the switch is exhaustive. - // However Closure Compiler does not understand that and reports an error in typed mode. - // The `throw new Error` below works around the problem, and the unexpected: never variable - // makes sure tsc still checks this code is unreachable. - var unexpected = name; - throw new Error("unexpected translation type " + unexpected); - } -} -/** - * Returns a date formatter that transforms a date and an offset into a timezone with ISO8601 or - * GMT format depending on the width (eg: short = +0430, short:GMT = GMT+4, long = GMT+04:30, - * extended = +04:30) - */ -function timeZoneGetter(width) { - return function (date, locale, offset) { - var zone = -1 * offset; - var minusSign = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign); - var hours = zone > 0 ? Math.floor(zone / 60) : Math.ceil(zone / 60); - switch (width) { - case ZoneWidth.Short: - return ((zone >= 0) ? '+' : '') + padNumber(hours, 2, minusSign) + - padNumber(Math.abs(zone % 60), 2, minusSign); - case ZoneWidth.ShortGMT: - return 'GMT' + ((zone >= 0) ? '+' : '') + padNumber(hours, 1, minusSign); - case ZoneWidth.Long: - return 'GMT' + ((zone >= 0) ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + - padNumber(Math.abs(zone % 60), 2, minusSign); - case ZoneWidth.Extended: - if (offset === 0) { - return 'Z'; - } - else { - return ((zone >= 0) ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + - padNumber(Math.abs(zone % 60), 2, minusSign); - } - default: - throw new Error("Unknown zone width \"" + width + "\""); - } - }; -} -var JANUARY = 0; -var THURSDAY = 4; -function getFirstThursdayOfYear(year) { - var firstDayOfYear = (new Date(year, JANUARY, 1)).getDay(); - return new Date(year, 0, 1 + ((firstDayOfYear <= THURSDAY) ? THURSDAY : THURSDAY + 7) - firstDayOfYear); -} -function getThursdayThisWeek(datetime) { - return new Date(datetime.getFullYear(), datetime.getMonth(), datetime.getDate() + (THURSDAY - datetime.getDay())); -} -function weekGetter(size, monthBased) { - if (monthBased === void 0) { monthBased = false; } - return function (date, locale) { - var result; - if (monthBased) { - var nbDaysBefore1stDayOfMonth = new Date(date.getFullYear(), date.getMonth(), 1).getDay() - 1; - var today = date.getDate(); - result = 1 + Math.floor((today + nbDaysBefore1stDayOfMonth) / 7); - } - else { - var firstThurs = getFirstThursdayOfYear(date.getFullYear()); - var thisThurs = getThursdayThisWeek(date); - var diff = thisThurs.getTime() - firstThurs.getTime(); - result = 1 + Math.round(diff / 6.048e8); // 6.048e8 ms per week - } - return padNumber(result, size, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign)); - }; -} -var DATE_FORMATS = {}; -// Based on CLDR formats: -// See complete list: http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table -// See also explanations: http://cldr.unicode.org/translation/date-time -// TODO(ocombe): support all missing cldr formats: Y, U, Q, D, F, e, c, j, J, C, A, v, V, X, x -function getDateFormatter(format) { - if (DATE_FORMATS[format]) { - return DATE_FORMATS[format]; - } - var formatter; - switch (format) { - // Era name (AD/BC) - case 'G': - case 'GG': - case 'GGG': - formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Abbreviated); - break; - case 'GGGG': - formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Wide); - break; - case 'GGGGG': - formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Narrow); - break; - // 1 digit representation of the year, e.g. (AD 1 => 1, AD 199 => 199) - case 'y': - formatter = dateGetter(DateType.FullYear, 1, 0, false, true); - break; - // 2 digit representation of the year, padded (00-99). (e.g. AD 2001 => 01, AD 2010 => 10) - case 'yy': - formatter = dateGetter(DateType.FullYear, 2, 0, true, true); - break; - // 3 digit representation of the year, padded (000-999). (e.g. AD 2001 => 01, AD 2010 => 10) - case 'yyy': - formatter = dateGetter(DateType.FullYear, 3, 0, false, true); - break; - // 4 digit representation of the year (e.g. AD 1 => 0001, AD 2010 => 2010) - case 'yyyy': - formatter = dateGetter(DateType.FullYear, 4, 0, false, true); - break; - // Month of the year (1-12), numeric - case 'M': - case 'L': - formatter = dateGetter(DateType.Month, 1, 1); - break; - case 'MM': - case 'LL': - formatter = dateGetter(DateType.Month, 2, 1); - break; - // Month of the year (January, ...), string, format - case 'MMM': - formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Abbreviated); - break; - case 'MMMM': - formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Wide); - break; - case 'MMMMM': - formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Narrow); - break; - // Month of the year (January, ...), string, standalone - case 'LLL': - formatter = - dateStrGetter(TranslationType.Months, TranslationWidth.Abbreviated, FormStyle.Standalone); - break; - case 'LLLL': - formatter = - dateStrGetter(TranslationType.Months, TranslationWidth.Wide, FormStyle.Standalone); - break; - case 'LLLLL': - formatter = - dateStrGetter(TranslationType.Months, TranslationWidth.Narrow, FormStyle.Standalone); - break; - // Week of the year (1, ... 52) - case 'w': - formatter = weekGetter(1); - break; - case 'ww': - formatter = weekGetter(2); - break; - // Week of the month (1, ...) - case 'W': - formatter = weekGetter(1, true); - break; - // Day of the month (1-31) - case 'd': - formatter = dateGetter(DateType.Date, 1); - break; - case 'dd': - formatter = dateGetter(DateType.Date, 2); - break; - // Day of the Week - case 'E': - case 'EE': - case 'EEE': - formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Abbreviated); - break; - case 'EEEE': - formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Wide); - break; - case 'EEEEE': - formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Narrow); - break; - case 'EEEEEE': - formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Short); - break; - // Generic period of the day (am-pm) - case 'a': - case 'aa': - case 'aaa': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated); - break; - case 'aaaa': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide); - break; - case 'aaaaa': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow); - break; - // Extended period of the day (midnight, at night, ...), standalone - case 'b': - case 'bb': - case 'bbb': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated, FormStyle.Standalone, true); - break; - case 'bbbb': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide, FormStyle.Standalone, true); - break; - case 'bbbbb': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow, FormStyle.Standalone, true); - break; - // Extended period of the day (midnight, night, ...), standalone - case 'B': - case 'BB': - case 'BBB': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated, FormStyle.Format, true); - break; - case 'BBBB': - formatter = - dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide, FormStyle.Format, true); - break; - case 'BBBBB': - formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow, FormStyle.Format, true); - break; - // Hour in AM/PM, (1-12) - case 'h': - formatter = dateGetter(DateType.Hours, 1, -12); - break; - case 'hh': - formatter = dateGetter(DateType.Hours, 2, -12); - break; - // Hour of the day (0-23) - case 'H': - formatter = dateGetter(DateType.Hours, 1); - break; - // Hour in day, padded (00-23) - case 'HH': - formatter = dateGetter(DateType.Hours, 2); - break; - // Minute of the hour (0-59) - case 'm': - formatter = dateGetter(DateType.Minutes, 1); - break; - case 'mm': - formatter = dateGetter(DateType.Minutes, 2); - break; - // Second of the minute (0-59) - case 's': - formatter = dateGetter(DateType.Seconds, 1); - break; - case 'ss': - formatter = dateGetter(DateType.Seconds, 2); - break; - // Fractional second - case 'S': - formatter = dateGetter(DateType.FractionalSeconds, 1); - break; - case 'SS': - formatter = dateGetter(DateType.FractionalSeconds, 2); - break; - case 'SSS': - formatter = dateGetter(DateType.FractionalSeconds, 3); - break; - // Timezone ISO8601 short format (-0430) - case 'Z': - case 'ZZ': - case 'ZZZ': - formatter = timeZoneGetter(ZoneWidth.Short); - break; - // Timezone ISO8601 extended format (-04:30) - case 'ZZZZZ': - formatter = timeZoneGetter(ZoneWidth.Extended); - break; - // Timezone GMT short format (GMT+4) - case 'O': - case 'OO': - case 'OOO': - // Should be location, but fallback to format O instead because we don't have the data yet - case 'z': - case 'zz': - case 'zzz': - formatter = timeZoneGetter(ZoneWidth.ShortGMT); - break; - // Timezone GMT long format (GMT+0430) - case 'OOOO': - case 'ZZZZ': - // Should be location, but fallback to format O instead because we don't have the data yet - case 'zzzz': - formatter = timeZoneGetter(ZoneWidth.Long); - break; - default: - return null; - } - DATE_FORMATS[format] = formatter; - return formatter; -} -function timezoneToOffset(timezone, fallback) { - // Support: IE 9-11 only, Edge 13-15+ - // IE/Edge do not "understand" colon (`:`) in timezone - timezone = timezone.replace(/:/g, ''); - var requestedTimezoneOffset = Date.parse('Jan 01, 1970 00:00:00 ' + timezone) / 60000; - return isNaN(requestedTimezoneOffset) ? fallback : requestedTimezoneOffset; -} -function addDateMinutes(date, minutes) { - date = new Date(date.getTime()); - date.setMinutes(date.getMinutes() + minutes); - return date; -} -function convertTimezoneToLocal(date, timezone, reverse) { - var reverseValue = reverse ? -1 : 1; - var dateTimezoneOffset = date.getTimezoneOffset(); - var timezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset); - return addDateMinutes(date, reverseValue * (timezoneOffset - dateTimezoneOffset)); -} -/** - * Converts a value to date. - * - * Supported input formats: - * - `Date` - * - number: timestamp - * - string: numeric (e.g. "1234"), ISO and date strings in a format supported by - * [Date.parse()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/parse). - * Note: ISO strings without time return a date without timeoffset. - * - * Throws if unable to convert to a date. - */ -function toDate(value) { - if (isDate(value)) { - return value; - } - if (typeof value === 'number' && !isNaN(value)) { - return new Date(value); - } - if (typeof value === 'string') { - value = value.trim(); - var parsedNb = parseFloat(value); - // any string that only contains numbers, like "1234" but not like "1234hello" - if (!isNaN(value - parsedNb)) { - return new Date(parsedNb); - } - if (/^(\d{4}-\d{1,2}-\d{1,2})$/.test(value)) { - /* For ISO Strings without time the day, month and year must be extracted from the ISO String - before Date creation to avoid time offset and errors in the new Date. - If we only replace '-' with ',' in the ISO String ("2015,01,01"), and try to create a new - date, some browsers (e.g. IE 9) will throw an invalid Date error. - If we leave the '-' ("2015-01-01") and try to create a new Date("2015-01-01") the timeoffset - is applied. - Note: ISO months are 0 for January, 1 for February, ... */ - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__read"])(value.split('-').map(function (val) { return +val; }), 3), y = _a[0], m = _a[1], d = _a[2]; - return new Date(y, m - 1, d); - } - var match = void 0; - if (match = value.match(ISO8601_DATE_REGEX)) { - return isoStringToDate(match); - } - } - var date = new Date(value); - if (!isDate(date)) { - throw new Error("Unable to convert \"" + value + "\" into a date"); - } - return date; -} -/** - * Converts a date in ISO8601 to a Date. - * Used instead of `Date.parse` because of browser discrepancies. - */ -function isoStringToDate(match) { - var date = new Date(0); - var tzHour = 0; - var tzMin = 0; - // match[8] means that the string contains "Z" (UTC) or a timezone like "+01:00" or "+0100" - var dateSetter = match[8] ? date.setUTCFullYear : date.setFullYear; - var timeSetter = match[8] ? date.setUTCHours : date.setHours; - // if there is a timezone defined like "+01:00" or "+0100" - if (match[9]) { - tzHour = Number(match[9] + match[10]); - tzMin = Number(match[9] + match[11]); - } - dateSetter.call(date, Number(match[1]), Number(match[2]) - 1, Number(match[3])); - var h = Number(match[4] || 0) - tzHour; - var m = Number(match[5] || 0) - tzMin; - var s = Number(match[6] || 0); - var ms = Math.round(parseFloat('0.' + (match[7] || 0)) * 1000); - timeSetter.call(date, h, m, s, ms); - return date; -} -function isDate(value) { - return value instanceof Date && !isNaN(value.valueOf()); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var NUMBER_FORMAT_REGEXP = /^(\d+)?\.((\d+)(-(\d+))?)?$/; -var MAX_DIGITS = 22; -var DECIMAL_SEP = '.'; -var ZERO_CHAR = '0'; -var PATTERN_SEP = ';'; -var GROUP_SEP = ','; -var DIGIT_CHAR = '#'; -var CURRENCY_CHAR = '¤'; -var PERCENT_CHAR = '%'; -/** - * Transforms a number to a locale string based on a style and a format. - */ -function formatNumberToLocaleString(value, pattern, locale, groupSymbol, decimalSymbol, digitsInfo, isPercent) { - if (isPercent === void 0) { isPercent = false; } - var formattedText = ''; - var isZero = false; - if (!isFinite(value)) { - formattedText = getLocaleNumberSymbol(locale, NumberSymbol.Infinity); - } - else { - var parsedNumber = parseNumber(value); - if (isPercent) { - parsedNumber = toPercent(parsedNumber); - } - var minInt = pattern.minInt; - var minFraction = pattern.minFrac; - var maxFraction = pattern.maxFrac; - if (digitsInfo) { - var parts = digitsInfo.match(NUMBER_FORMAT_REGEXP); - if (parts === null) { - throw new Error(digitsInfo + " is not a valid digit info"); - } - var minIntPart = parts[1]; - var minFractionPart = parts[3]; - var maxFractionPart = parts[5]; - if (minIntPart != null) { - minInt = parseIntAutoRadix(minIntPart); - } - if (minFractionPart != null) { - minFraction = parseIntAutoRadix(minFractionPart); - } - if (maxFractionPart != null) { - maxFraction = parseIntAutoRadix(maxFractionPart); - } - else if (minFractionPart != null && minFraction > maxFraction) { - maxFraction = minFraction; - } - } - roundNumber(parsedNumber, minFraction, maxFraction); - var digits = parsedNumber.digits; - var integerLen = parsedNumber.integerLen; - var exponent = parsedNumber.exponent; - var decimals = []; - isZero = digits.every(function (d) { return !d; }); - // pad zeros for small numbers - for (; integerLen < minInt; integerLen++) { - digits.unshift(0); - } - // pad zeros for small numbers - for (; integerLen < 0; integerLen++) { - digits.unshift(0); - } - // extract decimals digits - if (integerLen > 0) { - decimals = digits.splice(integerLen, digits.length); - } - else { - decimals = digits; - digits = [0]; - } - // format the integer digits with grouping separators - var groups = []; - if (digits.length >= pattern.lgSize) { - groups.unshift(digits.splice(-pattern.lgSize, digits.length).join('')); - } - while (digits.length > pattern.gSize) { - groups.unshift(digits.splice(-pattern.gSize, digits.length).join('')); - } - if (digits.length) { - groups.unshift(digits.join('')); - } - formattedText = groups.join(getLocaleNumberSymbol(locale, groupSymbol)); - // append the decimal digits - if (decimals.length) { - formattedText += getLocaleNumberSymbol(locale, decimalSymbol) + decimals.join(''); - } - if (exponent) { - formattedText += getLocaleNumberSymbol(locale, NumberSymbol.Exponential) + '+' + exponent; - } - } - if (value < 0 && !isZero) { - formattedText = pattern.negPre + formattedText + pattern.negSuf; - } - else { - formattedText = pattern.posPre + formattedText + pattern.posSuf; - } - return formattedText; -} -/** - * @ngModule CommonModule - * @description - * - * Formats a number as currency using locale rules. - * - * @param value The number to format. - * @param locale A locale code for the locale format rules to use. - * @param currency A string containing the currency symbol or its name, - * such as "$" or "Canadian Dollar". Used in output string, but does not affect the operation - * of the function. - * @param currencyCode The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) - * currency code, such as `USD` for the US dollar and `EUR` for the euro. - * Used to determine the number of digits in the decimal part. - * @param digitInfo Decimal representation options, specified by a string in the following format: - * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details. - * - * @returns The formatted currency value. - * - * @see `formatNumber()` - * @see `DecimalPipe` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function formatCurrency(value, locale, currency, currencyCode, digitsInfo) { - var format = getLocaleNumberFormat(locale, NumberFormatStyle.Currency); - var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign)); - pattern.minFrac = getNumberOfCurrencyDigits(currencyCode); - pattern.maxFrac = pattern.minFrac; - var res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.CurrencyGroup, NumberSymbol.CurrencyDecimal, digitsInfo); - return res - .replace(CURRENCY_CHAR, currency) - // if we have 2 time the currency character, the second one is ignored - .replace(CURRENCY_CHAR, ''); -} -/** - * @ngModule CommonModule - * @description - * - * Formats a number as a percentage according to locale rules. - * - * @param value The number to format. - * @param locale A locale code for the locale format rules to use. - * @param digitInfo Decimal representation options, specified by a string in the following format: - * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details. - * - * @returns The formatted percentage value. - * - * @see `formatNumber()` - * @see `DecimalPipe` - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * @publicApi - * - */ -function formatPercent(value, locale, digitsInfo) { - var format = getLocaleNumberFormat(locale, NumberFormatStyle.Percent); - var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign)); - var res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo, true); - return res.replace(new RegExp(PERCENT_CHAR, 'g'), getLocaleNumberSymbol(locale, NumberSymbol.PercentSign)); -} -/** - * @ngModule CommonModule - * @description - * - * Formats a number as text, with group sizing, separator, and other - * parameters based on the locale. - * - * @param value The number to format. - * @param locale A locale code for the locale format rules to use. - * @param digitInfo Decimal representation options, specified by a string in the following format: - * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details. - * - * @returns The formatted text string. - * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n) - * - * @publicApi - */ -function formatNumber(value, locale, digitsInfo) { - var format = getLocaleNumberFormat(locale, NumberFormatStyle.Decimal); - var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign)); - return formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo); -} -function parseNumberFormat(format, minusSign) { - if (minusSign === void 0) { minusSign = '-'; } - var p = { - minInt: 1, - minFrac: 0, - maxFrac: 0, - posPre: '', - posSuf: '', - negPre: '', - negSuf: '', - gSize: 0, - lgSize: 0 - }; - var patternParts = format.split(PATTERN_SEP); - var positive = patternParts[0]; - var negative = patternParts[1]; - var positiveParts = positive.indexOf(DECIMAL_SEP) !== -1 ? - positive.split(DECIMAL_SEP) : - [ - positive.substring(0, positive.lastIndexOf(ZERO_CHAR) + 1), - positive.substring(positive.lastIndexOf(ZERO_CHAR) + 1) - ], integer = positiveParts[0], fraction = positiveParts[1] || ''; - p.posPre = integer.substr(0, integer.indexOf(DIGIT_CHAR)); - for (var i = 0; i < fraction.length; i++) { - var ch = fraction.charAt(i); - if (ch === ZERO_CHAR) { - p.minFrac = p.maxFrac = i + 1; - } - else if (ch === DIGIT_CHAR) { - p.maxFrac = i + 1; - } - else { - p.posSuf += ch; - } - } - var groups = integer.split(GROUP_SEP); - p.gSize = groups[1] ? groups[1].length : 0; - p.lgSize = (groups[2] || groups[1]) ? (groups[2] || groups[1]).length : 0; - if (negative) { - var trunkLen = positive.length - p.posPre.length - p.posSuf.length, pos = negative.indexOf(DIGIT_CHAR); - p.negPre = negative.substr(0, pos).replace(/'/g, ''); - p.negSuf = negative.substr(pos + trunkLen).replace(/'/g, ''); - } - else { - p.negPre = minusSign + p.posPre; - p.negSuf = p.posSuf; - } - return p; -} -// Transforms a parsed number into a percentage by multiplying it by 100 -function toPercent(parsedNumber) { - // if the number is 0, don't do anything - if (parsedNumber.digits[0] === 0) { - return parsedNumber; - } - // Getting the current number of decimals - var fractionLen = parsedNumber.digits.length - parsedNumber.integerLen; - if (parsedNumber.exponent) { - parsedNumber.exponent += 2; - } - else { - if (fractionLen === 0) { - parsedNumber.digits.push(0, 0); - } - else if (fractionLen === 1) { - parsedNumber.digits.push(0); - } - parsedNumber.integerLen += 2; - } - return parsedNumber; -} -/** - * Parses a number. - * Significant bits of this parse algorithm came from https://github.com/MikeMcl/big.js/ - */ -function parseNumber(num) { - var numStr = Math.abs(num) + ''; - var exponent = 0, digits, integerLen; - var i, j, zeros; - // Decimal point? - if ((integerLen = numStr.indexOf(DECIMAL_SEP)) > -1) { - numStr = numStr.replace(DECIMAL_SEP, ''); - } - // Exponential form? - if ((i = numStr.search(/e/i)) > 0) { - // Work out the exponent. - if (integerLen < 0) - integerLen = i; - integerLen += +numStr.slice(i + 1); - numStr = numStr.substring(0, i); - } - else if (integerLen < 0) { - // There was no decimal point or exponent so it is an integer. - integerLen = numStr.length; - } - // Count the number of leading zeros. - for (i = 0; numStr.charAt(i) === ZERO_CHAR; i++) { /* empty */ - } - if (i === (zeros = numStr.length)) { - // The digits are all zero. - digits = [0]; - integerLen = 1; - } - else { - // Count the number of trailing zeros - zeros--; - while (numStr.charAt(zeros) === ZERO_CHAR) - zeros--; - // Trailing zeros are insignificant so ignore them - integerLen -= i; - digits = []; - // Convert string to array of digits without leading/trailing zeros. - for (j = 0; i <= zeros; i++, j++) { - digits[j] = Number(numStr.charAt(i)); - } - } - // If the number overflows the maximum allowed digits then use an exponent. - if (integerLen > MAX_DIGITS) { - digits = digits.splice(0, MAX_DIGITS - 1); - exponent = integerLen - 1; - integerLen = 1; - } - return { digits: digits, exponent: exponent, integerLen: integerLen }; -} -/** - * Round the parsed number to the specified number of decimal places - * This function changes the parsedNumber in-place - */ -function roundNumber(parsedNumber, minFrac, maxFrac) { - if (minFrac > maxFrac) { - throw new Error("The minimum number of digits after fraction (" + minFrac + ") is higher than the maximum (" + maxFrac + ")."); - } - var digits = parsedNumber.digits; - var fractionLen = digits.length - parsedNumber.integerLen; - var fractionSize = Math.min(Math.max(minFrac, fractionLen), maxFrac); - // The index of the digit to where rounding is to occur - var roundAt = fractionSize + parsedNumber.integerLen; - var digit = digits[roundAt]; - if (roundAt > 0) { - // Drop fractional digits beyond `roundAt` - digits.splice(Math.max(parsedNumber.integerLen, roundAt)); - // Set non-fractional digits beyond `roundAt` to 0 - for (var j = roundAt; j < digits.length; j++) { - digits[j] = 0; - } - } - else { - // We rounded to zero so reset the parsedNumber - fractionLen = Math.max(0, fractionLen); - parsedNumber.integerLen = 1; - digits.length = Math.max(1, roundAt = fractionSize + 1); - digits[0] = 0; - for (var i = 1; i < roundAt; i++) - digits[i] = 0; - } - if (digit >= 5) { - if (roundAt - 1 < 0) { - for (var k = 0; k > roundAt; k--) { - digits.unshift(0); - parsedNumber.integerLen++; - } - digits.unshift(1); - parsedNumber.integerLen++; - } - else { - digits[roundAt - 1]++; - } - } - // Pad out with zeros to get the required fraction length - for (; fractionLen < Math.max(0, fractionSize); fractionLen++) - digits.push(0); - var dropTrailingZeros = fractionSize !== 0; - // Minimal length = nb of decimals required + current nb of integers - // Any number besides that is optional and can be removed if it's a trailing 0 - var minLen = minFrac + parsedNumber.integerLen; - // Do any carrying, e.g. a digit was rounded up to 10 - var carry = digits.reduceRight(function (carry, d, i, digits) { - d = d + carry; - digits[i] = d < 10 ? d : d - 10; // d % 10 - if (dropTrailingZeros) { - // Do not keep meaningless fractional trailing zeros (e.g. 15.52000 --> 15.52) - if (digits[i] === 0 && i >= minLen) { - digits.pop(); - } - else { - dropTrailingZeros = false; - } - } - return d >= 10 ? 1 : 0; // Math.floor(d / 10); - }, 0); - if (carry) { - digits.unshift(carry); - parsedNumber.integerLen++; - } -} -function parseIntAutoRadix(text) { - var result = parseInt(text); - if (isNaN(result)) { - throw new Error('Invalid integer literal when parsing ' + text); - } - return result; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @deprecated from v5 - */ -var DEPRECATED_PLURAL_FN = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('UseV4Plurals'); -/** - * @publicApi - */ -var NgLocalization = /** @class */ (function () { - function NgLocalization() { - } - return NgLocalization; -}()); -/** - * Returns the plural category for a given value. - * - "=value" when the case exists, - * - the plural category otherwise - */ -function getPluralCategory(value, cases, ngLocalization, locale) { - var key = "=" + value; - if (cases.indexOf(key) > -1) { - return key; - } - key = ngLocalization.getPluralCategory(value, locale); - if (cases.indexOf(key) > -1) { - return key; - } - if (cases.indexOf('other') > -1) { - return 'other'; - } - throw new Error("No plural message found for value \"" + value + "\""); -} -/** - * Returns the plural case based on the locale - * - * @publicApi - */ -var NgLocaleLocalization = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__extends"])(NgLocaleLocalization, _super); - function NgLocaleLocalization(locale, - /** @deprecated from v5 */ - deprecatedPluralFn) { - var _this = _super.call(this) || this; - _this.locale = locale; - _this.deprecatedPluralFn = deprecatedPluralFn; - return _this; - } - NgLocaleLocalization.prototype.getPluralCategory = function (value, locale) { - var plural = this.deprecatedPluralFn ? this.deprecatedPluralFn(locale || this.locale, value) : - getLocalePluralCase(locale || this.locale)(value); - switch (plural) { - case Plural.Zero: - return 'zero'; - case Plural.One: - return 'one'; - case Plural.Two: - return 'two'; - case Plural.Few: - return 'few'; - case Plural.Many: - return 'many'; - default: - return 'other'; - } - }; - NgLocaleLocalization = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"])()), Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(1, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(DEPRECATED_PLURAL_FN)), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String, Object]) - ], NgLocaleLocalization); - return NgLocaleLocalization; -}(NgLocalization)); -/** - * Returns the plural case based on the locale - * - * @deprecated from v5 the plural case function is in locale data files common/locales/*.ts - * @publicApi - */ -function getPluralCase(locale, nLike) { - // TODO(vicb): lazy compute - if (typeof nLike === 'string') { - nLike = parseInt(nLike, 10); - } - var n = nLike; - var nDecimal = n.toString().replace(/^[^.]*\.?/, ''); - var i = Math.floor(Math.abs(n)); - var v = nDecimal.length; - var f = parseInt(nDecimal, 10); - var t = parseInt(n.toString().replace(/^[^.]*\.?|0+$/g, ''), 10) || 0; - var lang = locale.split('-')[0].toLowerCase(); - switch (lang) { - case 'af': - case 'asa': - case 'az': - case 'bem': - case 'bez': - case 'bg': - case 'brx': - case 'ce': - case 'cgg': - case 'chr': - case 'ckb': - case 'ee': - case 'el': - case 'eo': - case 'es': - case 'eu': - case 'fo': - case 'fur': - case 'gsw': - case 'ha': - case 'haw': - case 'hu': - case 'jgo': - case 'jmc': - case 'ka': - case 'kk': - case 'kkj': - case 'kl': - case 'ks': - case 'ksb': - case 'ky': - case 'lb': - case 'lg': - case 'mas': - case 'mgo': - case 'ml': - case 'mn': - case 'nb': - case 'nd': - case 'ne': - case 'nn': - case 'nnh': - case 'nyn': - case 'om': - case 'or': - case 'os': - case 'ps': - case 'rm': - case 'rof': - case 'rwk': - case 'saq': - case 'seh': - case 'sn': - case 'so': - case 'sq': - case 'ta': - case 'te': - case 'teo': - case 'tk': - case 'tr': - case 'ug': - case 'uz': - case 'vo': - case 'vun': - case 'wae': - case 'xog': - if (n === 1) - return Plural.One; - return Plural.Other; - case 'ak': - case 'ln': - case 'mg': - case 'pa': - case 'ti': - if (n === Math.floor(n) && n >= 0 && n <= 1) - return Plural.One; - return Plural.Other; - case 'am': - case 'as': - case 'bn': - case 'fa': - case 'gu': - case 'hi': - case 'kn': - case 'mr': - case 'zu': - if (i === 0 || n === 1) - return Plural.One; - return Plural.Other; - case 'ar': - if (n === 0) - return Plural.Zero; - if (n === 1) - return Plural.One; - if (n === 2) - return Plural.Two; - if (n % 100 === Math.floor(n % 100) && n % 100 >= 3 && n % 100 <= 10) - return Plural.Few; - if (n % 100 === Math.floor(n % 100) && n % 100 >= 11 && n % 100 <= 99) - return Plural.Many; - return Plural.Other; - case 'ast': - case 'ca': - case 'de': - case 'en': - case 'et': - case 'fi': - case 'fy': - case 'gl': - case 'it': - case 'nl': - case 'sv': - case 'sw': - case 'ur': - case 'yi': - if (i === 1 && v === 0) - return Plural.One; - return Plural.Other; - case 'be': - if (n % 10 === 1 && !(n % 100 === 11)) - return Plural.One; - if (n % 10 === Math.floor(n % 10) && n % 10 >= 2 && n % 10 <= 4 && - !(n % 100 >= 12 && n % 100 <= 14)) - return Plural.Few; - if (n % 10 === 0 || n % 10 === Math.floor(n % 10) && n % 10 >= 5 && n % 10 <= 9 || - n % 100 === Math.floor(n % 100) && n % 100 >= 11 && n % 100 <= 14) - return Plural.Many; - return Plural.Other; - case 'br': - if (n % 10 === 1 && !(n % 100 === 11 || n % 100 === 71 || n % 100 === 91)) - return Plural.One; - if (n % 10 === 2 && !(n % 100 === 12 || n % 100 === 72 || n % 100 === 92)) - return Plural.Two; - if (n % 10 === Math.floor(n % 10) && (n % 10 >= 3 && n % 10 <= 4 || n % 10 === 9) && - !(n % 100 >= 10 && n % 100 <= 19 || n % 100 >= 70 && n % 100 <= 79 || - n % 100 >= 90 && n % 100 <= 99)) - return Plural.Few; - if (!(n === 0) && n % 1e6 === 0) - return Plural.Many; - return Plural.Other; - case 'bs': - case 'hr': - case 'sr': - if (v === 0 && i % 10 === 1 && !(i % 100 === 11) || f % 10 === 1 && !(f % 100 === 11)) - return Plural.One; - if (v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 2 && i % 10 <= 4 && - !(i % 100 >= 12 && i % 100 <= 14) || - f % 10 === Math.floor(f % 10) && f % 10 >= 2 && f % 10 <= 4 && - !(f % 100 >= 12 && f % 100 <= 14)) - return Plural.Few; - return Plural.Other; - case 'cs': - case 'sk': - if (i === 1 && v === 0) - return Plural.One; - if (i === Math.floor(i) && i >= 2 && i <= 4 && v === 0) - return Plural.Few; - if (!(v === 0)) - return Plural.Many; - return Plural.Other; - case 'cy': - if (n === 0) - return Plural.Zero; - if (n === 1) - return Plural.One; - if (n === 2) - return Plural.Two; - if (n === 3) - return Plural.Few; - if (n === 6) - return Plural.Many; - return Plural.Other; - case 'da': - if (n === 1 || !(t === 0) && (i === 0 || i === 1)) - return Plural.One; - return Plural.Other; - case 'dsb': - case 'hsb': - if (v === 0 && i % 100 === 1 || f % 100 === 1) - return Plural.One; - if (v === 0 && i % 100 === 2 || f % 100 === 2) - return Plural.Two; - if (v === 0 && i % 100 === Math.floor(i % 100) && i % 100 >= 3 && i % 100 <= 4 || - f % 100 === Math.floor(f % 100) && f % 100 >= 3 && f % 100 <= 4) - return Plural.Few; - return Plural.Other; - case 'ff': - case 'fr': - case 'hy': - case 'kab': - if (i === 0 || i === 1) - return Plural.One; - return Plural.Other; - case 'fil': - if (v === 0 && (i === 1 || i === 2 || i === 3) || - v === 0 && !(i % 10 === 4 || i % 10 === 6 || i % 10 === 9) || - !(v === 0) && !(f % 10 === 4 || f % 10 === 6 || f % 10 === 9)) - return Plural.One; - return Plural.Other; - case 'ga': - if (n === 1) - return Plural.One; - if (n === 2) - return Plural.Two; - if (n === Math.floor(n) && n >= 3 && n <= 6) - return Plural.Few; - if (n === Math.floor(n) && n >= 7 && n <= 10) - return Plural.Many; - return Plural.Other; - case 'gd': - if (n === 1 || n === 11) - return Plural.One; - if (n === 2 || n === 12) - return Plural.Two; - if (n === Math.floor(n) && (n >= 3 && n <= 10 || n >= 13 && n <= 19)) - return Plural.Few; - return Plural.Other; - case 'gv': - if (v === 0 && i % 10 === 1) - return Plural.One; - if (v === 0 && i % 10 === 2) - return Plural.Two; - if (v === 0 && - (i % 100 === 0 || i % 100 === 20 || i % 100 === 40 || i % 100 === 60 || i % 100 === 80)) - return Plural.Few; - if (!(v === 0)) - return Plural.Many; - return Plural.Other; - case 'he': - if (i === 1 && v === 0) - return Plural.One; - if (i === 2 && v === 0) - return Plural.Two; - if (v === 0 && !(n >= 0 && n <= 10) && n % 10 === 0) - return Plural.Many; - return Plural.Other; - case 'is': - if (t === 0 && i % 10 === 1 && !(i % 100 === 11) || !(t === 0)) - return Plural.One; - return Plural.Other; - case 'ksh': - if (n === 0) - return Plural.Zero; - if (n === 1) - return Plural.One; - return Plural.Other; - case 'kw': - case 'naq': - case 'se': - case 'smn': - if (n === 1) - return Plural.One; - if (n === 2) - return Plural.Two; - return Plural.Other; - case 'lag': - if (n === 0) - return Plural.Zero; - if ((i === 0 || i === 1) && !(n === 0)) - return Plural.One; - return Plural.Other; - case 'lt': - if (n % 10 === 1 && !(n % 100 >= 11 && n % 100 <= 19)) - return Plural.One; - if (n % 10 === Math.floor(n % 10) && n % 10 >= 2 && n % 10 <= 9 && - !(n % 100 >= 11 && n % 100 <= 19)) - return Plural.Few; - if (!(f === 0)) - return Plural.Many; - return Plural.Other; - case 'lv': - case 'prg': - if (n % 10 === 0 || n % 100 === Math.floor(n % 100) && n % 100 >= 11 && n % 100 <= 19 || - v === 2 && f % 100 === Math.floor(f % 100) && f % 100 >= 11 && f % 100 <= 19) - return Plural.Zero; - if (n % 10 === 1 && !(n % 100 === 11) || v === 2 && f % 10 === 1 && !(f % 100 === 11) || - !(v === 2) && f % 10 === 1) - return Plural.One; - return Plural.Other; - case 'mk': - if (v === 0 && i % 10 === 1 || f % 10 === 1) - return Plural.One; - return Plural.Other; - case 'mt': - if (n === 1) - return Plural.One; - if (n === 0 || n % 100 === Math.floor(n % 100) && n % 100 >= 2 && n % 100 <= 10) - return Plural.Few; - if (n % 100 === Math.floor(n % 100) && n % 100 >= 11 && n % 100 <= 19) - return Plural.Many; - return Plural.Other; - case 'pl': - if (i === 1 && v === 0) - return Plural.One; - if (v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 2 && i % 10 <= 4 && - !(i % 100 >= 12 && i % 100 <= 14)) - return Plural.Few; - if (v === 0 && !(i === 1) && i % 10 === Math.floor(i % 10) && i % 10 >= 0 && i % 10 <= 1 || - v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 5 && i % 10 <= 9 || - v === 0 && i % 100 === Math.floor(i % 100) && i % 100 >= 12 && i % 100 <= 14) - return Plural.Many; - return Plural.Other; - case 'pt': - if (n === Math.floor(n) && n >= 0 && n <= 2 && !(n === 2)) - return Plural.One; - return Plural.Other; - case 'ro': - if (i === 1 && v === 0) - return Plural.One; - if (!(v === 0) || n === 0 || - !(n === 1) && n % 100 === Math.floor(n % 100) && n % 100 >= 1 && n % 100 <= 19) - return Plural.Few; - return Plural.Other; - case 'ru': - case 'uk': - if (v === 0 && i % 10 === 1 && !(i % 100 === 11)) - return Plural.One; - if (v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 2 && i % 10 <= 4 && - !(i % 100 >= 12 && i % 100 <= 14)) - return Plural.Few; - if (v === 0 && i % 10 === 0 || - v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 5 && i % 10 <= 9 || - v === 0 && i % 100 === Math.floor(i % 100) && i % 100 >= 11 && i % 100 <= 14) - return Plural.Many; - return Plural.Other; - case 'shi': - if (i === 0 || n === 1) - return Plural.One; - if (n === Math.floor(n) && n >= 2 && n <= 10) - return Plural.Few; - return Plural.Other; - case 'si': - if (n === 0 || n === 1 || i === 0 && f === 1) - return Plural.One; - return Plural.Other; - case 'sl': - if (v === 0 && i % 100 === 1) - return Plural.One; - if (v === 0 && i % 100 === 2) - return Plural.Two; - if (v === 0 && i % 100 === Math.floor(i % 100) && i % 100 >= 3 && i % 100 <= 4 || !(v === 0)) - return Plural.Few; - return Plural.Other; - case 'tzm': - if (n === Math.floor(n) && n >= 0 && n <= 1 || n === Math.floor(n) && n >= 11 && n <= 99) - return Plural.One; - return Plural.Other; - // When there is no specification, the default is always "other" - // Spec: http://cldr.unicode.org/index/cldr-spec/plural-rules - // > other (required—general plural form — also used if the language only has a single form) - default: - return Plural.Other; - } -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Register global data to be used internally by Angular. See the - * ["I18n guide"](guide/i18n#i18n-pipes) to know how to import additional locale data. - * - * @publicApi - */ -// The signature registerLocaleData(data: any, extraData?: any) is deprecated since v5.1 -function registerLocaleData(data, localeId, extraData) { - if (typeof localeId !== 'string') { - extraData = localeId; - localeId = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].LocaleId]; - } - localeId = localeId.toLowerCase().replace(/_/g, '-'); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLOCALE_DATA"][localeId] = data; - if (extraData) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLOCALE_DATA"][localeId][_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData] = extraData; - } -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function parseCookieValue(cookieStr, name) { - var e_1, _a; - name = encodeURIComponent(name); - try { - for (var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__values"])(cookieStr.split(';')), _c = _b.next(); !_c.done; _c = _b.next()) { - var cookie = _c.value; - var eqIndex = cookie.indexOf('='); - var _d = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__read"])(eqIndex == -1 ? [cookie, ''] : [cookie.slice(0, eqIndex), cookie.slice(eqIndex + 1)], 2), cookieName = _d[0], cookieValue = _d[1]; - if (cookieName.trim() === name) { - return decodeURIComponent(cookieValue); - } - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (_c && !_c.done && (_a = _b.return)) _a.call(_b); - } - finally { if (e_1) throw e_1.error; } - } - return null; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Used to diff and convert ngStyle/ngClass instructions into [style] and [class] bindings. - * - * ngStyle and ngClass both accept various forms of input and behave differently than that - * of how [style] and [class] behave in Angular. - * - * The differences are: - * - ngStyle and ngClass both **watch** their binding values for changes each time CD runs - * while [style] and [class] bindings do not (they check for identity changes) - * - ngStyle allows for unit-based keys (e.g. `{'max-width.px':value}`) and [style] does not - * - ngClass supports arrays of class values and [class] only accepts map and string values - * - ngClass allows for multiple className keys (space-separated) within an array or map - * (as the * key) while [class] only accepts a simple key/value map object - * - * Having Angular understand and adapt to all the different forms of behavior is complicated - * and unnecessary. Instead, ngClass and ngStyle should have their input values be converted - * into something that the core-level [style] and [class] bindings understand. - * - * This [StylingDiffer] class handles this conversion by creating a new input value each time - * the inner representation of the binding value have changed. - * - * ## Why do we care about ngStyle/ngClass? - * The styling algorithm code (documented inside of `render3/interfaces/styling.ts`) needs to - * respect and understand the styling values emitted through ngStyle and ngClass (when they - * are present and used in a template). - * - * Instead of having these directives manage styling on their own, they should be included - * into the Angular styling algorithm that exists for [style] and [class] bindings. - * - * Here's why: - * - * - If ngStyle/ngClass is used in combination with [style]/[class] bindings then the - * styles and classes would fall out of sync and be applied and updated at - * inconsistent times - * - Both ngClass/ngStyle do not respect [class.name] and [style.prop] bindings - * (they will write over them given the right combination of events) - * - * ``` - * - *

...
- * - * - *
...
- * ``` - * - ngClass/ngStyle were written as a directives and made use of maps, closures and other - * expensive data structures which were evaluated each time CD runs - */ -var StylingDiffer = /** @class */ (function () { - function StylingDiffer(_name, _options) { - this._name = _name; - this._options = _options; - this.value = null; - this._lastSetValue = null; - this._lastSetValueType = 0 /* Null */; - this._lastSetValueIdentityChange = false; - } - /** - * Sets (updates) the styling value within the differ. - * - * Only when `hasValueChanged` is called then this new value will be evaluted - * and checked against the previous value. - * - * @param value the new styling value provided from the ngClass/ngStyle binding - */ - StylingDiffer.prototype.setValue = function (value) { - if (Array.isArray(value)) { - this._lastSetValueType = 4 /* Array */; - } - else if (value instanceof Set) { - this._lastSetValueType = 8 /* Set */; - } - else if (value && typeof value === 'string') { - if (!(this._options & 4 /* AllowStringValue */)) { - throw new Error(this._name + ' string values are not allowed'); - } - this._lastSetValueType = 1 /* String */; - } - else { - this._lastSetValueType = value ? 2 /* Map */ : 0 /* Null */; - } - this._lastSetValueIdentityChange = true; - this._lastSetValue = value || null; - }; - /** - * Determines whether or not the value has changed. - * - * This function can be called right after `setValue()` is called, but it can also be - * called incase the existing value (if it's a collection) changes internally. If the - * value is indeed a collection it will do the necessary diffing work and produce a - * new object value as assign that to `value`. - * - * @returns whether or not the value has changed in some way. - */ - StylingDiffer.prototype.hasValueChanged = function () { - var valueHasChanged = this._lastSetValueIdentityChange; - if (!valueHasChanged && !(this._lastSetValueType & 14 /* Collection */)) - return false; - var finalValue = null; - var trimValues = (this._options & 1 /* TrimProperties */) ? true : false; - var parseOutUnits = (this._options & 8 /* AllowUnits */) ? true : false; - var allowSubKeys = (this._options & 2 /* AllowSubKeys */) ? true : false; - switch (this._lastSetValueType) { - // case 1: [input]="string" - case 1 /* String */: - var tokens = this._lastSetValue.split(/\s+/g); - if (this._options & 16 /* ForceAsMap */) { - finalValue = {}; - tokens.forEach(function (token, i) { return finalValue[token] = true; }); - } - else { - finalValue = tokens.reduce(function (str, token, i) { return str + (i ? ' ' : '') + token; }); - } - break; - // case 2: [input]="{key:value}" - case 2 /* Map */: - var map = this._lastSetValue; - var keys = Object.keys(map); - if (!valueHasChanged) { - if (this.value) { - // we know that the classExp value exists and that it is - // a map (otherwise an identity change would have occurred) - valueHasChanged = mapHasChanged(keys, this.value, map); - } - else { - valueHasChanged = true; - } - } - if (valueHasChanged) { - finalValue = - bulidMapFromValues(this._name, trimValues, parseOutUnits, allowSubKeys, map, keys); - } - break; - // case 3a: [input]="[str1, str2, ...]" - // case 3b: [input]="Set" - case 4 /* Array */: - case 8 /* Set */: - var values = Array.from(this._lastSetValue); - if (!valueHasChanged) { - var keys_1 = Object.keys(this.value); - valueHasChanged = !arrayEqualsArray(keys_1, values); - } - if (valueHasChanged) { - finalValue = - bulidMapFromValues(this._name, trimValues, parseOutUnits, allowSubKeys, values); - } - break; - // case 4: [input]="null|undefined" - default: - finalValue = null; - break; - } - if (valueHasChanged) { - this.value = finalValue; - } - return valueHasChanged; - }; - return StylingDiffer; -}()); -/** - * builds and returns a map based on the values input value - * - * If the `keys` param is provided then the `values` param is treated as a - * string map. Otherwise `values` is treated as a string array. - */ -function bulidMapFromValues(errorPrefix, trim, parseOutUnits, allowSubKeys, values, keys) { - var map = {}; - if (keys) { - // case 1: map - for (var i = 0; i < keys.length; i++) { - var key = keys[i]; - key = trim ? key.trim() : key; - var value = values[key]; - setMapValues(map, key, value, parseOutUnits, allowSubKeys); - } - } - else { - // case 2: array - for (var i = 0; i < values.length; i++) { - var value = values[i]; - assertValidValue(errorPrefix, value); - value = trim ? value.trim() : value; - setMapValues(map, value, true, false, allowSubKeys); - } - } - return map; -} -function assertValidValue(errorPrefix, value) { - if (typeof value !== 'string') { - throw new Error(errorPrefix + " can only toggle CSS classes expressed as strings, got " + value); - } -} -function setMapValues(map, key, value, parseOutUnits, allowSubKeys) { - if (allowSubKeys && key.indexOf(' ') > 0) { - var innerKeys = key.split(/\s+/g); - for (var j = 0; j < innerKeys.length; j++) { - setIndividualMapValue(map, innerKeys[j], value, parseOutUnits); - } - } - else { - setIndividualMapValue(map, key, value, parseOutUnits); - } -} -function setIndividualMapValue(map, key, value, parseOutUnits) { - if (parseOutUnits) { - var values = normalizeStyleKeyAndValue(key, value); - value = values.value; - key = values.key; - } - map[key] = value; -} -function normalizeStyleKeyAndValue(key, value) { - var index = key.indexOf('.'); - if (index > 0) { - var unit = key.substr(index + 1); // ignore the . ([width.px]="'40'" => "40px") - key = key.substring(0, index); - if (value != null) { // we should not convert null values to string - value += unit; - } - } - return { key: key, value: value }; -} -function mapHasChanged(keys, a, b) { - var oldKeys = Object.keys(a); - var newKeys = keys; - // the keys are different which means the map changed - if (!arrayEqualsArray(oldKeys, newKeys)) { - return true; - } - for (var i = 0; i < newKeys.length; i++) { - var key = newKeys[i]; - if (a[key] !== b[key]) { - return true; - } - } - return false; -} -function arrayEqualsArray(a, b) { - if (a && b) { - if (a.length !== b.length) - return false; - for (var i = 0; i < a.length; i++) { - if (b.indexOf(a[i]) === -1) - return false; - } - return true; - } - return false; -} - -/** - * Used as a token for an injected service within the NgClass directive. - * - * NgClass behaves differenly whether or not VE is being used or not. If - * present then the legacy ngClass diffing algorithm will be used as an - * injected service. Otherwise the new diffing algorithm (which delegates - * to the `[class]` binding) will be used. This toggle behavior is done so - * via the ivy_switch mechanism. - */ -var NgClassImpl = /** @class */ (function () { - function NgClassImpl() { - } - return NgClassImpl; -}()); -var NgClassR2Impl = /** @class */ (function () { - function NgClassR2Impl(_iterableDiffers, _keyValueDiffers, _ngEl, _renderer) { - this._iterableDiffers = _iterableDiffers; - this._keyValueDiffers = _keyValueDiffers; - this._ngEl = _ngEl; - this._renderer = _renderer; - this._initialClasses = []; - } - NgClassR2Impl.prototype.getValue = function () { return null; }; - NgClassR2Impl.prototype.setClass = function (value) { - this._removeClasses(this._initialClasses); - this._initialClasses = typeof value === 'string' ? value.split(/\s+/) : []; - this._applyClasses(this._initialClasses); - this._applyClasses(this._rawClass); - }; - NgClassR2Impl.prototype.setNgClass = function (value) { - this._removeClasses(this._rawClass); - this._applyClasses(this._initialClasses); - this._iterableDiffer = null; - this._keyValueDiffer = null; - this._rawClass = typeof value === 'string' ? value.split(/\s+/) : value; - if (this._rawClass) { - if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisListLikeIterable"])(this._rawClass)) { - this._iterableDiffer = this._iterableDiffers.find(this._rawClass).create(); - } - else { - this._keyValueDiffer = this._keyValueDiffers.find(this._rawClass).create(); - } - } - }; - NgClassR2Impl.prototype.applyChanges = function () { - if (this._iterableDiffer) { - var iterableChanges = this._iterableDiffer.diff(this._rawClass); - if (iterableChanges) { - this._applyIterableChanges(iterableChanges); - } - } - else if (this._keyValueDiffer) { - var keyValueChanges = this._keyValueDiffer.diff(this._rawClass); - if (keyValueChanges) { - this._applyKeyValueChanges(keyValueChanges); - } - } - }; - NgClassR2Impl.prototype._applyKeyValueChanges = function (changes) { - var _this = this; - changes.forEachAddedItem(function (record) { return _this._toggleClass(record.key, record.currentValue); }); - changes.forEachChangedItem(function (record) { return _this._toggleClass(record.key, record.currentValue); }); - changes.forEachRemovedItem(function (record) { - if (record.previousValue) { - _this._toggleClass(record.key, false); - } - }); - }; - NgClassR2Impl.prototype._applyIterableChanges = function (changes) { - var _this = this; - changes.forEachAddedItem(function (record) { - if (typeof record.item === 'string') { - _this._toggleClass(record.item, true); - } - else { - throw new Error("NgClass can only toggle CSS classes expressed as strings, got " + Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(record.item)); - } - }); - changes.forEachRemovedItem(function (record) { return _this._toggleClass(record.item, false); }); - }; - /** - * Applies a collection of CSS classes to the DOM element. - * - * For argument of type Set and Array CSS class names contained in those collections are always - * added. - * For argument of type Map CSS class name in the map's key is toggled based on the value (added - * for truthy and removed for falsy). - */ - NgClassR2Impl.prototype._applyClasses = function (rawClassVal) { - var _this = this; - if (rawClassVal) { - if (Array.isArray(rawClassVal) || rawClassVal instanceof Set) { - rawClassVal.forEach(function (klass) { return _this._toggleClass(klass, true); }); - } - else { - Object.keys(rawClassVal).forEach(function (klass) { return _this._toggleClass(klass, !!rawClassVal[klass]); }); - } - } - }; - /** - * Removes a collection of CSS classes from the DOM element. This is mostly useful for cleanup - * purposes. - */ - NgClassR2Impl.prototype._removeClasses = function (rawClassVal) { - var _this = this; - if (rawClassVal) { - if (Array.isArray(rawClassVal) || rawClassVal instanceof Set) { - rawClassVal.forEach(function (klass) { return _this._toggleClass(klass, false); }); - } - else { - Object.keys(rawClassVal).forEach(function (klass) { return _this._toggleClass(klass, false); }); - } - } - }; - NgClassR2Impl.prototype._toggleClass = function (klass, enabled) { - var _this = this; - klass = klass.trim(); - if (klass) { - klass.split(/\s+/g).forEach(function (klass) { - if (enabled) { - _this._renderer.addClass(_this._ngEl.nativeElement, klass); - } - else { - _this._renderer.removeClass(_this._ngEl.nativeElement, klass); - } - }); - } - }; - NgClassR2Impl = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"], - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]]) - ], NgClassR2Impl); - return NgClassR2Impl; -}()); -var NgClassR3Impl = /** @class */ (function () { - function NgClassR3Impl() { - this._value = null; - this._ngClassDiffer = new StylingDiffer('NgClass', 1 /* TrimProperties */ | - 2 /* AllowSubKeys */ | - 4 /* AllowStringValue */ | 16 /* ForceAsMap */); - this._classStringDiffer = null; - } - NgClassR3Impl.prototype.getValue = function () { return this._value; }; - NgClassR3Impl.prototype.setClass = function (value) { - // early exit incase the binding gets emitted as an empty value which - // means there is no reason to instantiate and diff the values... - if (!value && !this._classStringDiffer) - return; - this._classStringDiffer = this._classStringDiffer || - new StylingDiffer('class', 4 /* AllowStringValue */ | 16 /* ForceAsMap */); - this._classStringDiffer.setValue(value); - }; - NgClassR3Impl.prototype.setNgClass = function (value) { - this._ngClassDiffer.setValue(value); - }; - NgClassR3Impl.prototype.applyChanges = function () { - var classChanged = this._classStringDiffer ? this._classStringDiffer.hasValueChanged() : false; - var ngClassChanged = this._ngClassDiffer.hasValueChanged(); - if (classChanged || ngClassChanged) { - var value = this._ngClassDiffer.value; - if (this._classStringDiffer) { - var classValue = this._classStringDiffer.value; - if (classValue) { - value = value ? Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__assign"])({}, classValue, value) : classValue; - } - } - this._value = value; - } - }; - NgClassR3Impl = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])() - ], NgClassR3Impl); - return NgClassR3Impl; -}()); -// the implementation for both NgStyleR2Impl and NgStyleR3Impl are -// not ivy_switch'd away, instead they are only hooked up into the -// DI via NgStyle's directive's provider property. -var NgClassImplProvider__PRE_R3__ = { - provide: NgClassImpl, - useClass: NgClassR2Impl -}; -var NgClassImplProvider__POST_R3__ = { - provide: NgClassImpl, - useClass: NgClassR3Impl -}; -var NgClassImplProvider = NgClassImplProvider__PRE_R3__; - -/* - * NgClass (as well as NgStyle) behaves differently when loaded in the VE and when not. - * - * If the VE is present (which is for older versions of Angular) then NgClass will inject - * the legacy diffing algorithm as a service and delegate all styling changes to that. - * - * If the VE is not present then NgStyle will normalize (through the injected service) and - * then write all styling changes to the `[style]` binding directly (through a host binding). - * Then Angular will notice the host binding change and treat the changes as styling - * changes and apply them via the core styling instructions that exist within Angular. - */ -// used when the VE is present -var ngClassDirectiveDef__PRE_R3__ = undefined; -var ɵ0 = function () { }, ɵ1 = function () { }, ɵ2 = function (rf, ctx, elIndex) { - if (rf & 1 /* Create */) { - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵallocHostVars"])(1); - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵstyling"])(); - } - if (rf & 2 /* Update */) { - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassMap"])(ctx.getValue()); - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵstylingApply"])(); - } -}; -// used when the VE is not present (note the directive will -// never be instantiated normally because it is apart of a -// base class) -var ngClassDirectiveDef__POST_R3__ = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"])({ - type: ɵ0, - selectors: null, - factory: ɵ1, - hostBindings: ɵ2 -}); -var ngClassDirectiveDef = ngClassDirectiveDef__PRE_R3__; -/** - * Serves as the base non-VE container for NgClass. - * - * While this is a base class that NgClass extends from, the - * class itself acts as a container for non-VE code to setup - * a link to the `[class]` host binding (via the static - * `ngDirectiveDef` property on the class). - * - * Note that the `ngDirectiveDef` property's code is switched - * depending if VE is present or not (this allows for the - * binding code to be set only for newer versions of Angular). - * - * @publicApi - */ -var NgClassBase = /** @class */ (function () { - function NgClassBase(_delegate) { - this._delegate = _delegate; - } - NgClassBase.prototype.getValue = function () { return this._delegate.getValue(); }; - NgClassBase.ngDirectiveDef = ngClassDirectiveDef; - return NgClassBase; -}()); -/** - * @ngModule CommonModule - * - * @usageNotes - * ``` - * ... - * - * ... - * - * ... - * - * ... - * - * ... - * ``` - * - * @description - * - * Adds and removes CSS classes on an HTML element. - * - * The CSS classes are updated as follows, depending on the type of the expression evaluation: - * - `string` - the CSS classes listed in the string (space delimited) are added, - * - `Array` - the CSS classes declared as Array elements are added, - * - `Object` - keys are CSS classes that get added when the expression given in the value - * evaluates to a truthy value, otherwise they are removed. - * - * @publicApi - */ -var NgClass = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__extends"])(NgClass, _super); - function NgClass(delegate) { - return _super.call(this, delegate) || this; - } - Object.defineProperty(NgClass.prototype, "klass", { - set: function (value) { this._delegate.setClass(value); }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgClass.prototype, "ngClass", { - set: function (value) { - this._delegate.setNgClass(value); - }, - enumerable: true, - configurable: true - }); - NgClass.prototype.ngDoCheck = function () { this._delegate.applyChanges(); }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])('class'), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", String), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], NgClass.prototype, "klass", null); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])('ngClass'), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgClass.prototype, "ngClass", null); - NgClass = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngClass]', providers: [NgClassImplProvider] }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [NgClassImpl]) - ], NgClass); - return NgClass; -}(NgClassBase)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Instantiates a single {@link Component} type and inserts its Host View into current View. - * `NgComponentOutlet` provides a declarative approach for dynamic component creation. - * - * `NgComponentOutlet` requires a component type, if a falsy value is set the view will clear and - * any existing component will get destroyed. - * - * @usageNotes - * - * ### Fine tune control - * - * You can control the component creation process by using the following optional attributes: - * - * * `ngComponentOutletInjector`: Optional custom {@link Injector} that will be used as parent for - * the Component. Defaults to the injector of the current view container. - * - * * `ngComponentOutletContent`: Optional list of projectable nodes to insert into the content - * section of the component, if exists. - * - * * `ngComponentOutletNgModuleFactory`: Optional module factory to allow dynamically loading other - * module, then load a component from that module. - * - * ### Syntax - * - * Simple - * ``` - * - * ``` - * - * Customized injector/content - * ``` - * - * - * ``` - * - * Customized ngModuleFactory - * ``` - * - * - * ``` - * - * ### A simple example - * - * {@example common/ngComponentOutlet/ts/module.ts region='SimpleExample'} - * - * A more complete example with additional options: - * - * {@example common/ngComponentOutlet/ts/module.ts region='CompleteExample'} - * - * @publicApi - * @ngModule CommonModule - */ -var NgComponentOutlet = /** @class */ (function () { - function NgComponentOutlet(_viewContainerRef) { - this._viewContainerRef = _viewContainerRef; - this._componentRef = null; - this._moduleRef = null; - } - NgComponentOutlet.prototype.ngOnChanges = function (changes) { - this._viewContainerRef.clear(); - this._componentRef = null; - if (this.ngComponentOutlet) { - var elInjector = this.ngComponentOutletInjector || this._viewContainerRef.parentInjector; - if (changes['ngComponentOutletNgModuleFactory']) { - if (this._moduleRef) - this._moduleRef.destroy(); - if (this.ngComponentOutletNgModuleFactory) { - var parentModule = elInjector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModuleRef"]); - this._moduleRef = this.ngComponentOutletNgModuleFactory.create(parentModule.injector); - } - else { - this._moduleRef = null; - } - } - var componentFactoryResolver = this._moduleRef ? this._moduleRef.componentFactoryResolver : - elInjector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]); - var componentFactory = componentFactoryResolver.resolveComponentFactory(this.ngComponentOutlet); - this._componentRef = this._viewContainerRef.createComponent(componentFactory, this._viewContainerRef.length, elInjector, this.ngComponentOutletContent); - } - }; - NgComponentOutlet.prototype.ngOnDestroy = function () { - if (this._moduleRef) - this._moduleRef.destroy(); - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", _angular_core__WEBPACK_IMPORTED_MODULE_0__["Type"]) - ], NgComponentOutlet.prototype, "ngComponentOutlet", void 0); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]) - ], NgComponentOutlet.prototype, "ngComponentOutletInjector", void 0); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Array) - ], NgComponentOutlet.prototype, "ngComponentOutletContent", void 0); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModuleFactory"]) - ], NgComponentOutlet.prototype, "ngComponentOutletNgModuleFactory", void 0); - NgComponentOutlet = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngComponentOutlet]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]]) - ], NgComponentOutlet); - return NgComponentOutlet; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @publicApi - */ -var NgForOfContext = /** @class */ (function () { - function NgForOfContext($implicit, ngForOf, index, count) { - this.$implicit = $implicit; - this.ngForOf = ngForOf; - this.index = index; - this.count = count; - } - Object.defineProperty(NgForOfContext.prototype, "first", { - get: function () { return this.index === 0; }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgForOfContext.prototype, "last", { - get: function () { return this.index === this.count - 1; }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgForOfContext.prototype, "even", { - get: function () { return this.index % 2 === 0; }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgForOfContext.prototype, "odd", { - get: function () { return !this.even; }, - enumerable: true, - configurable: true - }); - return NgForOfContext; -}()); -/** - * A [structural directive](guide/structural-directives) that renders - * a template for each item in a collection. - * The directive is placed on an element, which becomes the parent - * of the cloned templates. - * - * The `ngForOf` directive is generally used in the - * [shorthand form](guide/structural-directives#the-asterisk--prefix) `*ngFor`. - * In this form, the template to be rendered for each iteration is the content - * of an anchor element containing the directive. - * - * The following example shows the shorthand syntax with some options, - * contained in an `
  • ` element. - * - * ``` - *
  • ...
  • - * ``` - * - * The shorthand form expands into a long form that uses the `ngForOf` selector - * on an `` element. - * The content of the `` element is the `
  • ` element that held the - * short-form directive. - * - * Here is the expanded version of the short-form example. - * - * ``` - * - *
  • ...
  • - *
    - * ``` - * - * Angular automatically expands the shorthand syntax as it compiles the template. - * The context for each embedded view is logically merged to the current component - * context according to its lexical position. - * - * When using the shorthand syntax, Angular allows only [one structural directive - * on an element](guide/structural-directives#one-structural-directive-per-host-element). - * If you want to iterate conditionally, for example, - * put the `*ngIf` on a container element that wraps the `*ngFor` element. - * For futher discussion, see - * [Structural Directives](guide/structural-directives#one-per-element). - * - * @usageNotes - * - * ### Local variables - * - * `NgForOf` provides exported values that can be aliased to local variables. - * For example: - * - * ``` - *
  • - * {{i}}/{{users.length}}. {{user}} default - *
  • - * ``` - * - * The following exported values can be aliased to local variables: - * - * - `$implicit: T`: The value of the individual items in the iterable (`ngForOf`). - * - `ngForOf: NgIterable`: The value of the iterable expression. Useful when the expression is - * more complex then a property access, for example when using the async pipe (`userStreams | - * async`). - * - `index: number`: The index of the current item in the iterable. - * - `first: boolean`: True when the item is the first item in the iterable. - * - `last: boolean`: True when the item is the last item in the iterable. - * - `even: boolean`: True when the item has an even index in the iterable. - * - `odd: boolean`: True when the item has an odd index in the iterable. - * - * ### Change propagation - * - * When the contents of the iterator changes, `NgForOf` makes the corresponding changes to the DOM: - * - * * When an item is added, a new instance of the template is added to the DOM. - * * When an item is removed, its template instance is removed from the DOM. - * * When items are reordered, their respective templates are reordered in the DOM. - * - * Angular uses object identity to track insertions and deletions within the iterator and reproduce - * those changes in the DOM. This has important implications for animations and any stateful - * controls that are present, such as `` elements that accept user input. Inserted rows can - * be animated in, deleted rows can be animated out, and unchanged rows retain any unsaved state - * such as user input. - * For more on animations, see [Transitions and Triggers](guide/transition-and-triggers). - * - * The identities of elements in the iterator can change while the data does not. - * This can happen, for example, if the iterator is produced from an RPC to the server, and that - * RPC is re-run. Even if the data hasn't changed, the second response produces objects with - * different identities, and Angular must tear down the entire DOM and rebuild it (as if all old - * elements were deleted and all new elements inserted). - * - * To avoid this expensive operation, you can customize the default tracking algorithm. - * by supplying the `trackBy` option to `NgForOf`. - * `trackBy` takes a function that has two arguments: `index` and `item`. - * If `trackBy` is given, Angular tracks changes by the return value of the function. - * - * @see [Structural Directives](guide/structural-directives) - * @ngModule CommonModule - * @publicApi - */ -var NgForOf = /** @class */ (function () { - function NgForOf(_viewContainer, _template, _differs) { - this._viewContainer = _viewContainer; - this._template = _template; - this._differs = _differs; - this._ngForOfDirty = true; - this._differ = null; - } - Object.defineProperty(NgForOf.prototype, "ngForOf", { - /** - * The value of the iterable expression, which can be used as a - * [template input variable](guide/structural-directives#template-input-variable). - */ - set: function (ngForOf) { - this._ngForOf = ngForOf; - this._ngForOfDirty = true; - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgForOf.prototype, "ngForTrackBy", { - get: function () { return this._trackByFn; }, - /** - * A function that defines how to track changes for items in the iterable. - * - * When items are added, moved, or removed in the iterable, - * the directive must re-render the appropriate DOM nodes. - * To minimize churn in the DOM, only nodes that have changed - * are re-rendered. - * - * By default, the change detector assumes that - * the object instance identifies the node in the iterable. - * When this function is supplied, the directive uses - * the result of calling this function to identify the item node, - * rather than the identity of the object itself. - * - * The function receives two inputs, - * the iteration index and the node object ID. - */ - set: function (fn) { - if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["isDevMode"])() && fn != null && typeof fn !== 'function') { - // TODO(vicb): use a log service once there is a public one available - if (console && console.warn) { - console.warn("trackBy must be a function, but received " + JSON.stringify(fn) + ". " + - "See https://angular.io/docs/ts/latest/api/common/index/NgFor-directive.html#!#change-propagation for more information."); - } - } - this._trackByFn = fn; - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgForOf.prototype, "ngForTemplate", { - /** - * A reference to the template that is stamped out for each item in the iterable. - * @see [template reference variable](guide/template-syntax#template-reference-variables--var-) - */ - set: function (value) { - // TODO(TS2.1): make TemplateRef>> once we move to TS v2.1 - // The current type is too restrictive; a template that just uses index, for example, - // should be acceptable. - if (value) { - this._template = value; - } - }, - enumerable: true, - configurable: true - }); - /** - * Applies the changes when needed. - */ - NgForOf.prototype.ngDoCheck = function () { - if (this._ngForOfDirty) { - this._ngForOfDirty = false; - // React on ngForOf changes only once all inputs have been initialized - var value = this._ngForOf; - if (!this._differ && value) { - try { - this._differ = this._differs.find(value).create(this.ngForTrackBy); - } - catch (_a) { - throw new Error("Cannot find a differ supporting object '" + value + "' of type '" + getTypeName(value) + "'. NgFor only supports binding to Iterables such as Arrays."); - } - } - } - if (this._differ) { - var changes = this._differ.diff(this._ngForOf); - if (changes) - this._applyChanges(changes); - } - }; - NgForOf.prototype._applyChanges = function (changes) { - var _this = this; - var insertTuples = []; - changes.forEachOperation(function (item, adjustedPreviousIndex, currentIndex) { - if (item.previousIndex == null) { - var view = _this._viewContainer.createEmbeddedView(_this._template, new NgForOfContext(null, _this._ngForOf, -1, -1), currentIndex === null ? undefined : currentIndex); - var tuple = new RecordViewTuple(item, view); - insertTuples.push(tuple); - } - else if (currentIndex == null) { - _this._viewContainer.remove(adjustedPreviousIndex === null ? undefined : adjustedPreviousIndex); - } - else if (adjustedPreviousIndex !== null) { - var view = _this._viewContainer.get(adjustedPreviousIndex); - _this._viewContainer.move(view, currentIndex); - var tuple = new RecordViewTuple(item, view); - insertTuples.push(tuple); - } - }); - for (var i = 0; i < insertTuples.length; i++) { - this._perViewChange(insertTuples[i].view, insertTuples[i].record); - } - for (var i = 0, ilen = this._viewContainer.length; i < ilen; i++) { - var viewRef = this._viewContainer.get(i); - viewRef.context.index = i; - viewRef.context.count = ilen; - viewRef.context.ngForOf = this._ngForOf; - } - changes.forEachIdentityChange(function (record) { - var viewRef = _this._viewContainer.get(record.currentIndex); - viewRef.context.$implicit = record.item; - }); - }; - NgForOf.prototype._perViewChange = function (view, record) { - view.context.$implicit = record.item; - }; - /** - * Asserts the correct type of the context for the template that `NgForOf` will render. - * - * The presence of this method is a signal to the Ivy template type-check compiler that the - * `NgForOf` structural directive renders its template with a specific context type. - */ - NgForOf.ngTemplateContextGuard = function (dir, ctx) { - return true; - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgForOf.prototype, "ngForOf", null); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Function), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Function]) - ], NgForOf.prototype, "ngForTrackBy", null); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]]) - ], NgForOf.prototype, "ngForTemplate", null); - NgForOf = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngFor][ngForOf]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"], - _angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]]) - ], NgForOf); - return NgForOf; -}()); -var RecordViewTuple = /** @class */ (function () { - function RecordViewTuple(record, view) { - this.record = record; - this.view = view; - } - return RecordViewTuple; -}()); -function getTypeName(type) { - return type['name'] || typeof type; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A structural directive that conditionally includes a template based on the value of - * an expression coerced to Boolean. - * When the expression evaluates to true, Angular renders the template - * provided in a `then` clause, and when false or null, - * Angular renders the template provided in an optional `else` clause. The default - * template for the `else` clause is blank. - * - * A [shorthand form](guide/structural-directives#the-asterisk--prefix) of the directive, - * `*ngIf="condition"`, is generally used, provided - * as an attribute of the anchor element for the inserted template. - * Angular expands this into a more explicit version, in which the anchor element - * is contained in an `` element. - * - * Simple form with shorthand syntax: - * - * ``` - *
    Content to render when condition is true.
    - * ``` - * - * Simple form with expanded syntax: - * - * ``` - *
    Content to render when condition is - * true.
    - * ``` - * - * Form with an "else" block: - * - * ``` - *
    Content to render when condition is true.
    - * Content to render when condition is false. - * ``` - * - * Shorthand form with "then" and "else" blocks: - * - * ``` - *
    - * Content to render when condition is true. - * Content to render when condition is false. - * ``` - * - * Form with storing the value locally: - * - * ``` - *
    {{value}}
    - * Content to render when value is null. - * ``` - * - * @usageNotes - * - * The `*ngIf` directive is most commonly used to conditionally show an inline template, - * as seen in the following example. - * The default `else` template is blank. - * - * {@example common/ngIf/ts/module.ts region='NgIfSimple'} - * - * ### Showing an alternative template using `else` - * - * To display a template when `expression` evaluates to false, use an `else` template - * binding as shown in the following example. - * The `else` binding points to an `` element labeled `#elseBlock`. - * The template can be defined anywhere in the component view, but is typically placed right after - * `ngIf` for readability. - * - * {@example common/ngIf/ts/module.ts region='NgIfElse'} - * - * ### Using an external `then` template - * - * In the previous example, the then-clause template is specified inline, as the content of the - * tag that contains the `ngIf` directive. You can also specify a template that is defined - * externally, by referencing a labeled `` element. When you do this, you can - * change which template to use at runtime, as shown in the following example. - * - * {@example common/ngIf/ts/module.ts region='NgIfThenElse'} - * - * ### Storing a conditional result in a variable - * - * You might want to show a set of properties from the same object. If you are waiting - * for asynchronous data, the object can be undefined. - * In this case, you can use `ngIf` and store the result of the condition in a local - * variable as shown in the the following example. - * - * {@example common/ngIf/ts/module.ts region='NgIfAs'} - * - * This code uses only one `AsyncPipe`, so only one subscription is created. - * The conditional statement stores the result of `userStream|async` in the local variable `user`. - * You can then bind the local `user` repeatedly. - * - * The conditional displays the data only if `userStream` returns a value, - * so you don't need to use the - * [safe-navigation-operator](guide/template-syntax#safe-navigation-operator) (`?.`) - * to guard against null values when accessing properties. - * You can display an alternative template while waiting for the data. - * - * ### Shorthand syntax - * - * The shorthand syntax `*ngIf` expands into two separate template specifications - * for the "then" and "else" clauses. For example, consider the following shorthand statement, - * that is meant to show a loading page while waiting for data to be loaded. - * - * ``` - *
    - * ... - *
    - * - * - *
    Loading...
    - *
    - * ``` - * - * You can see that the "else" clause references the `` - * with the `#loading` label, and the template for the "then" clause - * is provided as the content of the anchor element. - * - * However, when Angular expands the shorthand syntax, it creates - * another `` tag, with `ngIf` and `ngIfElse` directives. - * The anchor element containing the template for the "then" clause becomes - * the content of this unlabeled `` tag. - * - * ``` - * - *
    - * ... - *
    - *
    - * - * - *
    Loading...
    - *
    - * ``` - * - * The presence of the implicit template object has implications for the nesting of - * structural directives. For more on this subject, see - * [Structural Directives](https://angular.io/guide/structural-directives#one-per-element). - * - * @ngModule CommonModule - * @publicApi - */ -var NgIf = /** @class */ (function () { - function NgIf(_viewContainer, templateRef) { - this._viewContainer = _viewContainer; - this._context = new NgIfContext(); - this._thenTemplateRef = null; - this._elseTemplateRef = null; - this._thenViewRef = null; - this._elseViewRef = null; - this._thenTemplateRef = templateRef; - } - Object.defineProperty(NgIf.prototype, "ngIf", { - /** - * The Boolean expression to evaluate as the condition for showing a template. - */ - set: function (condition) { - this._context.$implicit = this._context.ngIf = condition; - this._updateView(); - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgIf.prototype, "ngIfThen", { - /** - * A template to show if the condition expression evaluates to true. - */ - set: function (templateRef) { - assertTemplate('ngIfThen', templateRef); - this._thenTemplateRef = templateRef; - this._thenViewRef = null; // clear previous view if any. - this._updateView(); - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(NgIf.prototype, "ngIfElse", { - /** - * A template to show if the condition expression evaluates to false. - */ - set: function (templateRef) { - assertTemplate('ngIfElse', templateRef); - this._elseTemplateRef = templateRef; - this._elseViewRef = null; // clear previous view if any. - this._updateView(); - }, - enumerable: true, - configurable: true - }); - NgIf.prototype._updateView = function () { - if (this._context.$implicit) { - if (!this._thenViewRef) { - this._viewContainer.clear(); - this._elseViewRef = null; - if (this._thenTemplateRef) { - this._thenViewRef = - this._viewContainer.createEmbeddedView(this._thenTemplateRef, this._context); - } - } - } - else { - if (!this._elseViewRef) { - this._viewContainer.clear(); - this._thenViewRef = null; - if (this._elseTemplateRef) { - this._elseViewRef = - this._viewContainer.createEmbeddedView(this._elseTemplateRef, this._context); - } - } - } - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgIf.prototype, "ngIf", null); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgIf.prototype, "ngIfThen", null); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgIf.prototype, "ngIfElse", null); - NgIf = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngIf]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]]) - ], NgIf); - return NgIf; -}()); -/** - * @publicApi - */ -var NgIfContext = /** @class */ (function () { - function NgIfContext() { - this.$implicit = null; - this.ngIf = null; - } - return NgIfContext; -}()); -function assertTemplate(property, templateRef) { - var isTemplateRefOrNull = !!(!templateRef || templateRef.createEmbeddedView); - if (!isTemplateRefOrNull) { - throw new Error(property + " must be a TemplateRef, but received '" + Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(templateRef) + "'."); - } -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var SwitchView = /** @class */ (function () { - function SwitchView(_viewContainerRef, _templateRef) { - this._viewContainerRef = _viewContainerRef; - this._templateRef = _templateRef; - this._created = false; - } - SwitchView.prototype.create = function () { - this._created = true; - this._viewContainerRef.createEmbeddedView(this._templateRef); - }; - SwitchView.prototype.destroy = function () { - this._created = false; - this._viewContainerRef.clear(); - }; - SwitchView.prototype.enforceState = function (created) { - if (created && !this._created) { - this.create(); - } - else if (!created && this._created) { - this.destroy(); - } - }; - return SwitchView; -}()); -/** - * @ngModule CommonModule - * - * @description A structural directive that adds or removes templates (displaying or hiding views) - * when the next match expression matches the switch expression. - * - * The `[ngSwitch]` directive on a container specifies an expression to match against. - * The expressions to match are provided by `ngSwitchCase` directives on views within the container. - * - Every view that matches is rendered. - * - If there are no matches, a view with the `ngSwitchDefault` directive is rendered. - * - Elements within the `[NgSwitch]` statement but outside of any `NgSwitchCase` - * or `ngSwitchDefault` directive are preserved at the location. - * - * @usageNotes - * Define a container element for the directive, and specify the switch expression - * to match against as an attribute: - * - * ``` - * - * ``` - * - * Within the container, `*ngSwitchCase` statements specify the match expressions - * as attributes. Include `*ngSwitchDefault` as the final case. - * - * ``` - * - * ... - * ... - * ... - * - * ``` - * - * ### Usage Examples - * - * The following example shows how to use more than one case to display the same view: - * - * ``` - * - * - * ... - * ... - * ... - * - * ... - * - * ``` - * - * The following example shows how cases can be nested: - * ``` - * - * ... - * ... - * ... - * - * - * - * - * - * ... - * - * ``` - * - * @publicApi - * @see `NgSwitchCase` - * @see `NgSwitchDefault` - * @see [Structural Directives](guide/structural-directives) - * - */ -var NgSwitch = /** @class */ (function () { - function NgSwitch() { - this._defaultUsed = false; - this._caseCount = 0; - this._lastCaseCheckIndex = 0; - this._lastCasesMatched = false; - } - Object.defineProperty(NgSwitch.prototype, "ngSwitch", { - set: function (newValue) { - this._ngSwitch = newValue; - if (this._caseCount === 0) { - this._updateDefaultCases(true); - } - }, - enumerable: true, - configurable: true - }); - /** @internal */ - NgSwitch.prototype._addCase = function () { return this._caseCount++; }; - /** @internal */ - NgSwitch.prototype._addDefault = function (view) { - if (!this._defaultViews) { - this._defaultViews = []; - } - this._defaultViews.push(view); - }; - /** @internal */ - NgSwitch.prototype._matchCase = function (value) { - var matched = value == this._ngSwitch; - this._lastCasesMatched = this._lastCasesMatched || matched; - this._lastCaseCheckIndex++; - if (this._lastCaseCheckIndex === this._caseCount) { - this._updateDefaultCases(!this._lastCasesMatched); - this._lastCaseCheckIndex = 0; - this._lastCasesMatched = false; - } - return matched; - }; - NgSwitch.prototype._updateDefaultCases = function (useDefault) { - if (this._defaultViews && useDefault !== this._defaultUsed) { - this._defaultUsed = useDefault; - for (var i = 0; i < this._defaultViews.length; i++) { - var defaultView = this._defaultViews[i]; - defaultView.enforceState(useDefault); - } - } - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgSwitch.prototype, "ngSwitch", null); - NgSwitch = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngSwitch]' }) - ], NgSwitch); - return NgSwitch; -}()); -/** - * @ngModule CommonModule - * - * @description - * Provides a switch case expression to match against an enclosing `ngSwitch` expression. - * When the expressions match, the given `NgSwitchCase` template is rendered. - * If multiple match expressions match the switch expression value, all of them are displayed. - * - * @usageNotes - * - * Within a switch container, `*ngSwitchCase` statements specify the match expressions - * as attributes. Include `*ngSwitchDefault` as the final case. - * - * ``` - * - * ... - * ... - * ... - * - * ``` - * - * Each switch-case statement contains an in-line HTML template or template reference - * that defines the subtree to be selected if the value of the match expression - * matches the value of the switch expression. - * - * Unlike JavaScript, which uses strict equality, Angular uses loose equality. - * This means that the empty string, `""` matches 0. - * - * @publicApi - * @see `NgSwitch` - * @see `NgSwitchDefault` - * - */ -var NgSwitchCase = /** @class */ (function () { - function NgSwitchCase(viewContainer, templateRef, ngSwitch) { - this.ngSwitch = ngSwitch; - ngSwitch._addCase(); - this._view = new SwitchView(viewContainer, templateRef); - } - /** - * Performs case matching. For internal use only. - */ - NgSwitchCase.prototype.ngDoCheck = function () { this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase)); }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object) - ], NgSwitchCase.prototype, "ngSwitchCase", void 0); - NgSwitchCase = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngSwitchCase]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(2, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"])()), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"], - NgSwitch]) - ], NgSwitchCase); - return NgSwitchCase; -}()); -/** - * @ngModule CommonModule - * - * @description - * - * Creates a view that is rendered when no `NgSwitchCase` expressions - * match the `NgSwitch` expression. - * This statement should be the final case in an `NgSwitch`. - * - * @publicApi - * @see `NgSwitch` - * @see `NgSwitchCase` - * - */ -var NgSwitchDefault = /** @class */ (function () { - function NgSwitchDefault(viewContainer, templateRef, ngSwitch) { - ngSwitch._addDefault(new SwitchView(viewContainer, templateRef)); - } - NgSwitchDefault = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngSwitchDefault]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(2, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"])()), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"], - NgSwitch]) - ], NgSwitchDefault); - return NgSwitchDefault; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * - * @usageNotes - * ``` - * - * there is nothing - * there is one - * there are a few - * - * ``` - * - * @description - * - * Adds / removes DOM sub-trees based on a numeric value. Tailored for pluralization. - * - * Displays DOM sub-trees that match the switch expression value, or failing that, DOM sub-trees - * that match the switch expression's pluralization category. - * - * To use this directive you must provide a container element that sets the `[ngPlural]` attribute - * to a switch expression. Inner elements with a `[ngPluralCase]` will display based on their - * expression: - * - if `[ngPluralCase]` is set to a value starting with `=`, it will only display if the value - * matches the switch expression exactly, - * - otherwise, the view will be treated as a "category match", and will only display if exact - * value matches aren't found and the value maps to its category for the defined locale. - * - * See http://cldr.unicode.org/index/cldr-spec/plural-rules - * - * @publicApi - */ -var NgPlural = /** @class */ (function () { - function NgPlural(_localization) { - this._localization = _localization; - this._caseViews = {}; - } - Object.defineProperty(NgPlural.prototype, "ngPlural", { - set: function (value) { - this._switchValue = value; - this._updateView(); - }, - enumerable: true, - configurable: true - }); - NgPlural.prototype.addCase = function (value, switchView) { this._caseViews[value] = switchView; }; - NgPlural.prototype._updateView = function () { - this._clearViews(); - var cases = Object.keys(this._caseViews); - var key = getPluralCategory(this._switchValue, cases, this._localization); - this._activateView(this._caseViews[key]); - }; - NgPlural.prototype._clearViews = function () { - if (this._activeView) - this._activeView.destroy(); - }; - NgPlural.prototype._activateView = function (view) { - if (view) { - this._activeView = view; - this._activeView.create(); - } - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Number), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Number]) - ], NgPlural.prototype, "ngPlural", null); - NgPlural = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngPlural]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [NgLocalization]) - ], NgPlural); - return NgPlural; -}()); -/** - * @ngModule CommonModule - * - * @description - * - * Creates a view that will be added/removed from the parent {@link NgPlural} when the - * given expression matches the plural expression according to CLDR rules. - * - * @usageNotes - * ``` - * - * ... - * ... - * - *``` - * - * See {@link NgPlural} for more details and example. - * - * @publicApi - */ -var NgPluralCase = /** @class */ (function () { - function NgPluralCase(value, template, viewContainer, ngPlural) { - this.value = value; - var isANumber = !isNaN(Number(value)); - ngPlural.addCase(isANumber ? "=" + value : value, new SwitchView(viewContainer, template)); - } - NgPluralCase = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngPluralCase]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Attribute"])('ngPluralCase')), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(3, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"])()), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String, _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"], - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"], NgPlural]) - ], NgPluralCase); - return NgPluralCase; -}()); - -/** - * Used as a token for an injected service within the NgStyle directive. - * - * NgStyle behaves differenly whether or not VE is being used or not. If - * present then the legacy ngClass diffing algorithm will be used as an - * injected service. Otherwise the new diffing algorithm (which delegates - * to the `[style]` binding) will be used. This toggle behavior is done so - * via the ivy_switch mechanism. - */ -var NgStyleImpl = /** @class */ (function () { - function NgStyleImpl() { - } - return NgStyleImpl; -}()); -var NgStyleR2Impl = /** @class */ (function () { - function NgStyleR2Impl(_ngEl, _differs, _renderer) { - this._ngEl = _ngEl; - this._differs = _differs; - this._renderer = _renderer; - } - NgStyleR2Impl.prototype.getValue = function () { return null; }; - /** - * A map of style properties, specified as colon-separated - * key-value pairs. - * * The key is a style name, with an optional `.` suffix - * (such as 'top.px', 'font-style.em'). - * * The value is an expression to be evaluated. - */ - NgStyleR2Impl.prototype.setNgStyle = function (values) { - this._ngStyle = values; - if (!this._differ && values) { - this._differ = this._differs.find(values).create(); - } - }; - /** - * Applies the new styles if needed. - */ - NgStyleR2Impl.prototype.applyChanges = function () { - if (this._differ) { - var changes = this._differ.diff(this._ngStyle); - if (changes) { - this._applyChanges(changes); - } - } - }; - NgStyleR2Impl.prototype._applyChanges = function (changes) { - var _this = this; - changes.forEachRemovedItem(function (record) { return _this._setStyle(record.key, null); }); - changes.forEachAddedItem(function (record) { return _this._setStyle(record.key, record.currentValue); }); - changes.forEachChangedItem(function (record) { return _this._setStyle(record.key, record.currentValue); }); - }; - NgStyleR2Impl.prototype._setStyle = function (nameAndUnit, value) { - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__read"])(nameAndUnit.split('.'), 2), name = _a[0], unit = _a[1]; - value = value != null && unit ? "" + value + unit : value; - if (value != null) { - this._renderer.setStyle(this._ngEl.nativeElement, name, value); - } - else { - this._renderer.removeStyle(this._ngEl.nativeElement, name); - } - }; - NgStyleR2Impl = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]]) - ], NgStyleR2Impl); - return NgStyleR2Impl; -}()); -var NgStyleR3Impl = /** @class */ (function () { - function NgStyleR3Impl() { - this._differ = new StylingDiffer('NgStyle', 8 /* AllowUnits */); - this._value = null; - } - NgStyleR3Impl.prototype.getValue = function () { return this._value; }; - NgStyleR3Impl.prototype.setNgStyle = function (value) { this._differ.setValue(value); }; - NgStyleR3Impl.prototype.applyChanges = function () { - if (this._differ.hasValueChanged()) { - this._value = this._differ.value; - } - }; - NgStyleR3Impl = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])() - ], NgStyleR3Impl); - return NgStyleR3Impl; -}()); -// the implementation for both NgClassR2Impl and NgClassR3Impl are -// not ivy_switch'd away, instead they are only hooked up into the -// DI via NgStyle's directive's provider property. -var NgStyleImplProvider__PRE_R3__ = { - provide: NgStyleImpl, - useClass: NgStyleR2Impl -}; -var NgStyleImplProvider__POST_R3__ = { - provide: NgStyleImpl, - useClass: NgStyleR3Impl -}; -var NgStyleImplProvider = NgStyleImplProvider__PRE_R3__; - -/* - * NgStyle (as well as NgClass) behaves differently when loaded in the VE and when not. - * - * If the VE is present (which is for older versions of Angular) then NgStyle will inject - * the legacy diffing algorithm as a service and delegate all styling changes to that. - * - * If the VE is not present then NgStyle will normalize (through the injected service) and - * then write all styling changes to the `[style]` binding directly (through a host binding). - * Then Angular will notice the host binding change and treat the changes as styling - * changes and apply them via the core styling instructions that exist within Angular. - */ -// used when the VE is present -var ngStyleDirectiveDef__PRE_R3__ = undefined; -var ɵ0$1 = function () { }, ɵ1$1 = function () { }, ɵ2$1 = function (rf, ctx, elIndex) { - if (rf & 1 /* Create */) { - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵstyling"])(); - } - if (rf & 2 /* Update */) { - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵstyleMap"])(ctx.getValue()); - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵstylingApply"])(); - } -}; -// used when the VE is not present (note the directive will -// never be instantiated normally because it is apart of a -// base class) -var ngStyleDirectiveDef__POST_R3__ = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"])({ - type: ɵ0$1, - selectors: null, - factory: ɵ1$1, - hostBindings: ɵ2$1 -}); -var ngStyleDirectiveDef = ngStyleDirectiveDef__PRE_R3__; -/** - * Serves as the base non-VE container for NgStyle. - * - * While this is a base class that NgStyle extends from, the - * class itself acts as a container for non-VE code to setup - * a link to the `[style]` host binding (via the static - * `ngDirectiveDef` property on the class). - * - * Note that the `ngDirectiveDef` property's code is switched - * depending if VE is present or not (this allows for the - * binding code to be set only for newer versions of Angular). - * - * @publicApi - */ -var NgStyleBase = /** @class */ (function () { - function NgStyleBase(_delegate) { - this._delegate = _delegate; - } - NgStyleBase.prototype.getValue = function () { return this._delegate.getValue(); }; - NgStyleBase.ngDirectiveDef = ngStyleDirectiveDef; - return NgStyleBase; -}()); -/** - * @ngModule CommonModule - * - * @usageNotes - * - * Set the font of the containing element to the result of an expression. - * - * ``` - * ... - * ``` - * - * Set the width of the containing element to a pixel value returned by an expression. - * - * ``` - * ... - * ``` - * - * Set a collection of style values using an expression that returns key-value pairs. - * - * ``` - * ... - * ``` - * - * @description - * - * An attribute directive that updates styles for the containing HTML element. - * Sets one or more style properties, specified as colon-separated key-value pairs. - * The key is a style name, with an optional `.` suffix - * (such as 'top.px', 'font-style.em'). - * The value is an expression to be evaluated. - * The resulting non-null value, expressed in the given unit, - * is assigned to the given style property. - * If the result of evaluation is null, the corresponding style is removed. - * - * @publicApi - */ -var NgStyle = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__extends"])(NgStyle, _super); - function NgStyle(delegate) { - return _super.call(this, delegate) || this; - } - Object.defineProperty(NgStyle.prototype, "ngStyle", { - set: function (value) { this._delegate.setNgStyle(value); }, - enumerable: true, - configurable: true - }); - NgStyle.prototype.ngDoCheck = function () { this._delegate.applyChanges(); }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])('ngStyle'), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [Object]) - ], NgStyle.prototype, "ngStyle", null); - NgStyle = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngStyle]', providers: [NgStyleImplProvider] }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [NgStyleImpl]) - ], NgStyle); - return NgStyle; -}(NgStyleBase)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * - * @description - * - * Inserts an embedded view from a prepared `TemplateRef`. - * - * You can attach a context object to the `EmbeddedViewRef` by setting `[ngTemplateOutletContext]`. - * `[ngTemplateOutletContext]` should be an object, the object's keys will be available for binding - * by the local template `let` declarations. - * - * @usageNotes - * ``` - * - * ``` - * - * Using the key `$implicit` in the context object will set its value as default. - * - * ### Example - * - * {@example common/ngTemplateOutlet/ts/module.ts region='NgTemplateOutlet'} - * - * @publicApi - */ -var NgTemplateOutlet = /** @class */ (function () { - function NgTemplateOutlet(_viewContainerRef) { - this._viewContainerRef = _viewContainerRef; - this._viewRef = null; - /** - * A context object to attach to the {@link EmbeddedViewRef}. This should be an - * object, the object's keys will be available for binding by the local template `let` - * declarations. - * Using the key `$implicit` in the context object will set its value as default. - */ - this.ngTemplateOutletContext = null; - /** - * A string defining the template reference and optionally the context object for the template. - */ - this.ngTemplateOutlet = null; - } - NgTemplateOutlet.prototype.ngOnChanges = function (changes) { - var recreateView = this._shouldRecreateView(changes); - if (recreateView) { - if (this._viewRef) { - this._viewContainerRef.remove(this._viewContainerRef.indexOf(this._viewRef)); - } - if (this.ngTemplateOutlet) { - this._viewRef = this._viewContainerRef.createEmbeddedView(this.ngTemplateOutlet, this.ngTemplateOutletContext); - } - } - else { - if (this._viewRef && this.ngTemplateOutletContext) { - this._updateExistingContext(this.ngTemplateOutletContext); - } - } - }; - /** - * We need to re-create existing embedded view if: - * - templateRef has changed - * - context has changes - * - * We mark context object as changed when the corresponding object - * shape changes (new properties are added or existing properties are removed). - * In other words we consider context with the same properties as "the same" even - * if object reference changes (see https://github.com/angular/angular/issues/13407). - */ - NgTemplateOutlet.prototype._shouldRecreateView = function (changes) { - var ctxChange = changes['ngTemplateOutletContext']; - return !!changes['ngTemplateOutlet'] || (ctxChange && this._hasContextShapeChanged(ctxChange)); - }; - NgTemplateOutlet.prototype._hasContextShapeChanged = function (ctxChange) { - var e_1, _a; - var prevCtxKeys = Object.keys(ctxChange.previousValue || {}); - var currCtxKeys = Object.keys(ctxChange.currentValue || {}); - if (prevCtxKeys.length === currCtxKeys.length) { - try { - for (var currCtxKeys_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__values"])(currCtxKeys), currCtxKeys_1_1 = currCtxKeys_1.next(); !currCtxKeys_1_1.done; currCtxKeys_1_1 = currCtxKeys_1.next()) { - var propName = currCtxKeys_1_1.value; - if (prevCtxKeys.indexOf(propName) === -1) { - return true; - } - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (currCtxKeys_1_1 && !currCtxKeys_1_1.done && (_a = currCtxKeys_1.return)) _a.call(currCtxKeys_1); - } - finally { if (e_1) throw e_1.error; } - } - return false; - } - else { - return true; - } - }; - NgTemplateOutlet.prototype._updateExistingContext = function (ctx) { - var e_2, _a; - try { - for (var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__values"])(Object.keys(ctx)), _c = _b.next(); !_c.done; _c = _b.next()) { - var propName = _c.value; - this._viewRef.context[propName] = this.ngTemplateOutletContext[propName]; - } - } - catch (e_2_1) { e_2 = { error: e_2_1 }; } - finally { - try { - if (_c && !_c.done && (_a = _b.return)) _a.call(_b); - } - finally { if (e_2) throw e_2.error; } - } - }; - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object) - ], NgTemplateOutlet.prototype, "ngTemplateOutletContext", void 0); - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"])(), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:type", Object) - ], NgTemplateOutlet.prototype, "ngTemplateOutlet", void 0); - NgTemplateOutlet = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"])({ selector: '[ngTemplateOutlet]' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]]) - ], NgTemplateOutlet); - return NgTemplateOutlet; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A collection of Angular directives that are likely to be used in each and every Angular - * application. - */ -var COMMON_DIRECTIVES = [ - NgClass, - NgComponentOutlet, - NgForOf, - NgIf, - NgTemplateOutlet, - NgStyle, - NgSwitch, - NgSwitchCase, - NgSwitchDefault, - NgPlural, - NgPluralCase, -]; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function invalidPipeArgumentError(type, value) { - return Error("InvalidPipeArgument: '" + value + "' for pipe '" + Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(type) + "'"); -} - -var NumberFormatter = /** @class */ (function () { - function NumberFormatter() { - } - NumberFormatter.format = function (num, locale, style, opts) { - if (opts === void 0) { opts = {}; } - var minimumIntegerDigits = opts.minimumIntegerDigits, minimumFractionDigits = opts.minimumFractionDigits, maximumFractionDigits = opts.maximumFractionDigits, currency = opts.currency, _a = opts.currencyAsSymbol, currencyAsSymbol = _a === void 0 ? false : _a; - var options = { - minimumIntegerDigits: minimumIntegerDigits, - minimumFractionDigits: minimumFractionDigits, - maximumFractionDigits: maximumFractionDigits, - style: NumberFormatStyle[style].toLowerCase() - }; - if (style == NumberFormatStyle.Currency) { - options.currency = typeof currency == 'string' ? currency : undefined; - options.currencyDisplay = currencyAsSymbol ? 'symbol' : 'code'; - } - return new Intl.NumberFormat(locale, options).format(num); - }; - return NumberFormatter; -}()); -var DATE_FORMATS_SPLIT$1 = /((?:[^yMLdHhmsazZEwGjJ']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|J+|j+|m+|s+|a|z|Z|G+|w+))(.*)/; -var PATTERN_ALIASES = { - // Keys are quoted so they do not get renamed during closure compilation. - 'yMMMdjms': datePartGetterFactory(combine([ - digitCondition('year', 1), - nameCondition('month', 3), - digitCondition('day', 1), - digitCondition('hour', 1), - digitCondition('minute', 1), - digitCondition('second', 1), - ])), - 'yMdjm': datePartGetterFactory(combine([ - digitCondition('year', 1), digitCondition('month', 1), digitCondition('day', 1), - digitCondition('hour', 1), digitCondition('minute', 1) - ])), - 'yMMMMEEEEd': datePartGetterFactory(combine([ - digitCondition('year', 1), nameCondition('month', 4), nameCondition('weekday', 4), - digitCondition('day', 1) - ])), - 'yMMMMd': datePartGetterFactory(combine([digitCondition('year', 1), nameCondition('month', 4), digitCondition('day', 1)])), - 'yMMMd': datePartGetterFactory(combine([digitCondition('year', 1), nameCondition('month', 3), digitCondition('day', 1)])), - 'yMd': datePartGetterFactory(combine([digitCondition('year', 1), digitCondition('month', 1), digitCondition('day', 1)])), - 'jms': datePartGetterFactory(combine([digitCondition('hour', 1), digitCondition('second', 1), digitCondition('minute', 1)])), - 'jm': datePartGetterFactory(combine([digitCondition('hour', 1), digitCondition('minute', 1)])) -}; -var DATE_FORMATS$1 = { - // Keys are quoted so they do not get renamed. - 'yyyy': datePartGetterFactory(digitCondition('year', 4)), - 'yy': datePartGetterFactory(digitCondition('year', 2)), - 'y': datePartGetterFactory(digitCondition('year', 1)), - 'MMMM': datePartGetterFactory(nameCondition('month', 4)), - 'MMM': datePartGetterFactory(nameCondition('month', 3)), - 'MM': datePartGetterFactory(digitCondition('month', 2)), - 'M': datePartGetterFactory(digitCondition('month', 1)), - 'LLLL': datePartGetterFactory(nameCondition('month', 4)), - 'L': datePartGetterFactory(nameCondition('month', 1)), - 'dd': datePartGetterFactory(digitCondition('day', 2)), - 'd': datePartGetterFactory(digitCondition('day', 1)), - 'HH': digitModifier(hourExtractor(datePartGetterFactory(hour12Modify(digitCondition('hour', 2), false)))), - 'H': hourExtractor(datePartGetterFactory(hour12Modify(digitCondition('hour', 1), false))), - 'hh': digitModifier(hourExtractor(datePartGetterFactory(hour12Modify(digitCondition('hour', 2), true)))), - 'h': hourExtractor(datePartGetterFactory(hour12Modify(digitCondition('hour', 1), true))), - 'jj': datePartGetterFactory(digitCondition('hour', 2)), - 'j': datePartGetterFactory(digitCondition('hour', 1)), - 'mm': digitModifier(datePartGetterFactory(digitCondition('minute', 2))), - 'm': datePartGetterFactory(digitCondition('minute', 1)), - 'ss': digitModifier(datePartGetterFactory(digitCondition('second', 2))), - 's': datePartGetterFactory(digitCondition('second', 1)), - // while ISO 8601 requires fractions to be prefixed with `.` or `,` - // we can be just safely rely on using `sss` since we currently don't support single or two digit - // fractions - 'sss': datePartGetterFactory(digitCondition('second', 3)), - 'EEEE': datePartGetterFactory(nameCondition('weekday', 4)), - 'EEE': datePartGetterFactory(nameCondition('weekday', 3)), - 'EE': datePartGetterFactory(nameCondition('weekday', 2)), - 'E': datePartGetterFactory(nameCondition('weekday', 1)), - 'a': hourClockExtractor(datePartGetterFactory(hour12Modify(digitCondition('hour', 1), true))), - 'Z': timeZoneGetter$1('short'), - 'z': timeZoneGetter$1('long'), - 'ww': datePartGetterFactory({}), - // first Thursday of the year. not support ? - 'w': datePartGetterFactory({}), - // of the year not support ? - 'G': datePartGetterFactory(nameCondition('era', 1)), - 'GG': datePartGetterFactory(nameCondition('era', 2)), - 'GGG': datePartGetterFactory(nameCondition('era', 3)), - 'GGGG': datePartGetterFactory(nameCondition('era', 4)) -}; -function digitModifier(inner) { - return function (date, locale) { - var result = inner(date, locale); - return result.length == 1 ? '0' + result : result; - }; -} -function hourClockExtractor(inner) { - return function (date, locale) { return inner(date, locale).split(' ')[1]; }; -} -function hourExtractor(inner) { - return function (date, locale) { return inner(date, locale).split(' ')[0]; }; -} -function intlDateFormat(date, locale, options) { - return new Intl.DateTimeFormat(locale, options).format(date).replace(/[\u200e\u200f]/g, ''); -} -function timeZoneGetter$1(timezone) { - // To workaround `Intl` API restriction for single timezone let format with 24 hours - var options = { hour: '2-digit', hour12: false, timeZoneName: timezone }; - return function (date, locale) { - var result = intlDateFormat(date, locale, options); - // Then extract first 3 letters that related to hours - return result ? result.substring(3) : ''; - }; -} -function hour12Modify(options, value) { - options.hour12 = value; - return options; -} -function digitCondition(prop, len) { - var result = {}; - result[prop] = len === 2 ? '2-digit' : 'numeric'; - return result; -} -function nameCondition(prop, len) { - var result = {}; - if (len < 4) { - result[prop] = len > 1 ? 'short' : 'narrow'; - } - else { - result[prop] = 'long'; - } - return result; -} -function combine(options) { - return options.reduce(function (merged, opt) { return (Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__assign"])({}, merged, opt)); }, {}); -} -function datePartGetterFactory(ret) { - return function (date, locale) { return intlDateFormat(date, locale, ret); }; -} -var DATE_FORMATTER_CACHE = new Map(); -function dateFormatter(format, date, locale) { - var fn = PATTERN_ALIASES[format]; - if (fn) - return fn(date, locale); - var cacheKey = format; - var parts = DATE_FORMATTER_CACHE.get(cacheKey); - if (!parts) { - parts = []; - var match = void 0; - DATE_FORMATS_SPLIT$1.exec(format); - var _format = format; - while (_format) { - match = DATE_FORMATS_SPLIT$1.exec(_format); - if (match) { - parts = parts.concat(match.slice(1)); - _format = parts.pop(); - } - else { - parts.push(_format); - _format = null; - } - } - DATE_FORMATTER_CACHE.set(cacheKey, parts); - } - return parts.reduce(function (text, part) { - var fn = DATE_FORMATS$1[part]; - return text + (fn ? fn(date, locale) : partToTime(part)); - }, ''); -} -function partToTime(part) { - return part === '\'\'' ? '\'' : part.replace(/(^'|'$)/g, '').replace(/''/g, '\''); -} -var DateFormatter = /** @class */ (function () { - function DateFormatter() { - } - DateFormatter.format = function (date, locale, pattern) { - return dateFormatter(pattern, date, locale); - }; - return DateFormatter; -}()); - -/** -* @license -* Copyright Google Inc. All Rights Reserved. -* -* 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 - */ -/** - * @ngModule CommonModule - * @description - * - * Formats a date according to locale rules. - * - * Where: - * - `expression` is a date object or a number (milliseconds since UTC epoch) or an ISO string - * (https://www.w3.org/TR/NOTE-datetime). - * - `format` indicates which date/time components to include. The format can be predefined as - * shown below or custom as shown in the table. - * - `'medium'`: equivalent to `'yMMMdjms'` (e.g. `Sep 3, 2010, 12:05:08 PM` for `en-US`) - * - `'short'`: equivalent to `'yMdjm'` (e.g. `9/3/2010, 12:05 PM` for `en-US`) - * - `'fullDate'`: equivalent to `'yMMMMEEEEd'` (e.g. `Friday, September 3, 2010` for `en-US`) - * - `'longDate'`: equivalent to `'yMMMMd'` (e.g. `September 3, 2010` for `en-US`) - * - `'mediumDate'`: equivalent to `'yMMMd'` (e.g. `Sep 3, 2010` for `en-US`) - * - `'shortDate'`: equivalent to `'yMd'` (e.g. `9/3/2010` for `en-US`) - * - `'mediumTime'`: equivalent to `'jms'` (e.g. `12:05:08 PM` for `en-US`) - * - `'shortTime'`: equivalent to `'jm'` (e.g. `12:05 PM` for `en-US`) - * - * - * | Component | Symbol | Narrow | Short Form | Long Form | Numeric | 2-digit | - * |-----------|:------:|--------|--------------|-------------------|-----------|-----------| - * | era | G | G (A) | GGG (AD) | GGGG (Anno Domini)| - | - | - * | year | y | - | - | - | y (2015) | yy (15) | - * | month | M | L (S) | MMM (Sep) | MMMM (September) | M (9) | MM (09) | - * | day | d | - | - | - | d (3) | dd (03) | - * | weekday | E | E (S) | EEE (Sun) | EEEE (Sunday) | - | - | - * | hour | j | - | - | - | j (13) | jj (13) | - * | hour12 | h | - | - | - | h (1 PM) | hh (01 PM)| - * | hour24 | H | - | - | - | H (13) | HH (13) | - * | minute | m | - | - | - | m (5) | mm (05) | - * | second | s | - | - | - | s (9) | ss (09) | - * | timezone | z | - | - | z (Pacific Standard Time)| - | - | - * | timezone | Z | - | Z (GMT-8:00) | - | - | - | - * | timezone | a | - | a (PM) | - | - | - | - * - * In javascript, only the components specified will be respected (not the ordering, - * punctuations, ...) and details of the formatting will be dependent on the locale. - * - * Timezone of the formatted text will be the local system timezone of the end-user's machine. - * - * When the expression is a ISO string without time (e.g. 2016-09-19) the time zone offset is not - * applied and the formatted text will have the same day, month and year of the expression. - * - * WARNINGS: - * - this pipe is marked as pure hence it will not be re-evaluated when the input is mutated. - * Instead users should treat the date as an immutable object and change the reference when the - * pipe needs to re-run (this is to avoid reformatting the date on every change detection run - * which would be an expensive operation). - * - this pipe uses the Internationalization API. Therefore it is only reliable in Chrome and Opera - * browsers. - * - * @usageNotes - * - * ### Examples - * - * Assuming `dateObj` is (year: 2010, month: 9, day: 3, hour: 12 PM, minute: 05, second: 08) - * in the _local_ time and locale is 'en-US': - * - * {@example common/pipes/ts/date_pipe.ts region='DeprecatedDatePipe'} - * - * @publicApi - */ -var DeprecatedDatePipe = /** @class */ (function () { - function DeprecatedDatePipe(_locale) { - this._locale = _locale; - } - DeprecatedDatePipe_1 = DeprecatedDatePipe; - DeprecatedDatePipe.prototype.transform = function (value, pattern) { - if (pattern === void 0) { pattern = 'mediumDate'; } - if (value == null || value === '' || value !== value) - return null; - var date; - if (typeof value === 'string') { - value = value.trim(); - } - if (isDate$1(value)) { - date = value; - } - else if (!isNaN(value - parseFloat(value))) { - date = new Date(parseFloat(value)); - } - else if (typeof value === 'string' && /^(\d{4}-\d{1,2}-\d{1,2})$/.test(value)) { - /** - * For ISO Strings without time the day, month and year must be extracted from the ISO String - * before Date creation to avoid time offset and errors in the new Date. - * If we only replace '-' with ',' in the ISO String ("2015,01,01"), and try to create a new - * date, some browsers (e.g. IE 9) will throw an invalid Date error - * If we leave the '-' ("2015-01-01") and try to create a new Date("2015-01-01") the - * timeoffset - * is applied - * Note: ISO months are 0 for January, 1 for February, ... - */ - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__read"])(value.split('-').map(function (val) { return parseInt(val, 10); }), 3), y = _a[0], m = _a[1], d = _a[2]; - date = new Date(y, m - 1, d); - } - else { - date = new Date(value); - } - if (!isDate$1(date)) { - var match = void 0; - if ((typeof value === 'string') && (match = value.match(ISO8601_DATE_REGEX))) { - date = isoStringToDate(match); - } - else { - throw invalidPipeArgumentError(DeprecatedDatePipe_1, value); - } - } - return DateFormatter.format(date, this._locale, DeprecatedDatePipe_1._ALIASES[pattern] || pattern); - }; - var DeprecatedDatePipe_1; - /** @internal */ - DeprecatedDatePipe._ALIASES = { - 'medium': 'yMMMdjms', - 'short': 'yMdjm', - 'fullDate': 'yMMMMEEEEd', - 'longDate': 'yMMMMd', - 'mediumDate': 'yMMMd', - 'shortDate': 'yMd', - 'mediumTime': 'jms', - 'shortTime': 'jm' - }; - DeprecatedDatePipe = DeprecatedDatePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'date', pure: true }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DeprecatedDatePipe); - return DeprecatedDatePipe; -}()); -function isDate$1(value) { - return value instanceof Date && !isNaN(value.valueOf()); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function formatNumber$1(pipe, locale, value, style, digits, currency, currencyAsSymbol) { - if (currency === void 0) { currency = null; } - if (currencyAsSymbol === void 0) { currencyAsSymbol = false; } - if (value == null) - return null; - // Convert strings to numbers - value = typeof value === 'string' && !isNaN(+value - parseFloat(value)) ? +value : value; - if (typeof value !== 'number') { - throw invalidPipeArgumentError(pipe, value); - } - var minInt; - var minFraction; - var maxFraction; - if (style !== NumberFormatStyle.Currency) { - // rely on Intl default for currency - minInt = 1; - minFraction = 0; - maxFraction = 3; - } - if (digits) { - var parts = digits.match(NUMBER_FORMAT_REGEXP); - if (parts === null) { - throw new Error(digits + " is not a valid digit info for number pipes"); - } - if (parts[1] != null) { // min integer digits - minInt = parseIntAutoRadix(parts[1]); - } - if (parts[3] != null) { // min fraction digits - minFraction = parseIntAutoRadix(parts[3]); - } - if (parts[5] != null) { // max fraction digits - maxFraction = parseIntAutoRadix(parts[5]); - } - } - return NumberFormatter.format(value, locale, style, { - minimumIntegerDigits: minInt, - minimumFractionDigits: minFraction, - maximumFractionDigits: maxFraction, - currency: currency, - currencyAsSymbol: currencyAsSymbol, - }); -} -/** - * Formats a number as text. Group sizing and separator and other locale-specific - * configurations are based on the active locale. - * - * where `expression` is a number: - * - `digitInfo` is a `string` which has a following format:
    - * {minIntegerDigits}.{minFractionDigits}-{maxFractionDigits} - * - `minIntegerDigits` is the minimum number of integer digits to use. Defaults to `1`. - * - `minFractionDigits` is the minimum number of digits after fraction. Defaults to `0`. - * - `maxFractionDigits` is the maximum number of digits after fraction. Defaults to `3`. - * - * For more information on the acceptable range for each of these numbers and other - * details see your native internationalization library. - * - * WARNING: this pipe uses the Internationalization API which is not yet available in all browsers - * and may require a polyfill. See [Browser Support](guide/browser-support) for details. - * - * @usageNotes - * - * ### Example - * - * {@example common/pipes/ts/number_pipe.ts region='DeprecatedNumberPipe'} - * - * @ngModule CommonModule - * @publicApi - */ -var DeprecatedDecimalPipe = /** @class */ (function () { - function DeprecatedDecimalPipe(_locale) { - this._locale = _locale; - } - DeprecatedDecimalPipe_1 = DeprecatedDecimalPipe; - DeprecatedDecimalPipe.prototype.transform = function (value, digits) { - return formatNumber$1(DeprecatedDecimalPipe_1, this._locale, value, NumberFormatStyle.Decimal, digits); - }; - var DeprecatedDecimalPipe_1; - DeprecatedDecimalPipe = DeprecatedDecimalPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'number' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DeprecatedDecimalPipe); - return DeprecatedDecimalPipe; -}()); -/** - * @ngModule CommonModule - * - * @description - * - * Formats a number as percentage according to locale rules. - * - * - `digitInfo` See {@link DecimalPipe} for detailed description. - * - * WARNING: this pipe uses the Internationalization API which is not yet available in all browsers - * and may require a polyfill. See [Browser Support](guide/browser-support) for details. - * - * @usageNotes - * - * ### Example - * - * {@example common/pipes/ts/percent_pipe.ts region='DeprecatedPercentPipe'} - * - * @publicApi - */ -var DeprecatedPercentPipe = /** @class */ (function () { - function DeprecatedPercentPipe(_locale) { - this._locale = _locale; - } - DeprecatedPercentPipe_1 = DeprecatedPercentPipe; - DeprecatedPercentPipe.prototype.transform = function (value, digits) { - return formatNumber$1(DeprecatedPercentPipe_1, this._locale, value, NumberFormatStyle.Percent, digits); - }; - var DeprecatedPercentPipe_1; - DeprecatedPercentPipe = DeprecatedPercentPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'percent' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DeprecatedPercentPipe); - return DeprecatedPercentPipe; -}()); -/** - * @ngModule CommonModule - * @description - * - * Formats a number as currency using locale rules. - * - * Use `currency` to format a number as currency. - * - * - `currencyCode` is the [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code, such - * as `USD` for the US dollar and `EUR` for the euro. - * - `symbolDisplay` is a boolean indicating whether to use the currency symbol or code. - * - `true`: use symbol (e.g. `$`). - * - `false`(default): use code (e.g. `USD`). - * - `digitInfo` See {@link DecimalPipe} for detailed description. - * - * WARNING: this pipe uses the Internationalization API which is not yet available in all browsers - * and may require a polyfill. See [Browser Support](guide/browser-support) for details. - * - * @usageNotes - * - * ### Example - * - * {@example common/pipes/ts/currency_pipe.ts region='DeprecatedCurrencyPipe'} - * - * @publicApi - */ -var DeprecatedCurrencyPipe = /** @class */ (function () { - function DeprecatedCurrencyPipe(_locale) { - this._locale = _locale; - } - DeprecatedCurrencyPipe_1 = DeprecatedCurrencyPipe; - DeprecatedCurrencyPipe.prototype.transform = function (value, currencyCode, symbolDisplay, digits) { - if (currencyCode === void 0) { currencyCode = 'USD'; } - if (symbolDisplay === void 0) { symbolDisplay = false; } - return formatNumber$1(DeprecatedCurrencyPipe_1, this._locale, value, NumberFormatStyle.Currency, digits, currencyCode, symbolDisplay); - }; - var DeprecatedCurrencyPipe_1; - DeprecatedCurrencyPipe = DeprecatedCurrencyPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'currency' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DeprecatedCurrencyPipe); - return DeprecatedCurrencyPipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A collection of deprecated i18n pipes that require intl api - * - * @deprecated from v5 - */ -var COMMON_DEPRECATED_I18N_PIPES = [DeprecatedDecimalPipe, DeprecatedPercentPipe, DeprecatedCurrencyPipe, DeprecatedDatePipe]; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var ObservableStrategy = /** @class */ (function () { - function ObservableStrategy() { - } - ObservableStrategy.prototype.createSubscription = function (async, updateLatestValue) { - return async.subscribe({ next: updateLatestValue, error: function (e) { throw e; } }); - }; - ObservableStrategy.prototype.dispose = function (subscription) { subscription.unsubscribe(); }; - ObservableStrategy.prototype.onDestroy = function (subscription) { subscription.unsubscribe(); }; - return ObservableStrategy; -}()); -var PromiseStrategy = /** @class */ (function () { - function PromiseStrategy() { - } - PromiseStrategy.prototype.createSubscription = function (async, updateLatestValue) { - return async.then(updateLatestValue, function (e) { throw e; }); - }; - PromiseStrategy.prototype.dispose = function (subscription) { }; - PromiseStrategy.prototype.onDestroy = function (subscription) { }; - return PromiseStrategy; -}()); -var _promiseStrategy = new PromiseStrategy(); -var _observableStrategy = new ObservableStrategy(); -/** - * @ngModule CommonModule - * @description - * - * Unwraps a value from an asynchronous primitive. - * - * The `async` pipe subscribes to an `Observable` or `Promise` and returns the latest value it has - * emitted. When a new value is emitted, the `async` pipe marks the component to be checked for - * changes. When the component gets destroyed, the `async` pipe unsubscribes automatically to avoid - * potential memory leaks. - * - * @usageNotes - * - * ### Examples - * - * This example binds a `Promise` to the view. Clicking the `Resolve` button resolves the - * promise. - * - * {@example common/pipes/ts/async_pipe.ts region='AsyncPipePromise'} - * - * It's also possible to use `async` with Observables. The example below binds the `time` Observable - * to the view. The Observable continuously updates the view with the current time. - * - * {@example common/pipes/ts/async_pipe.ts region='AsyncPipeObservable'} - * - * @publicApi - */ -var AsyncPipe = /** @class */ (function () { - function AsyncPipe(_ref) { - this._ref = _ref; - this._latestValue = null; - this._latestReturnedValue = null; - this._subscription = null; - this._obj = null; - this._strategy = null; - } - AsyncPipe_1 = AsyncPipe; - AsyncPipe.prototype.ngOnDestroy = function () { - if (this._subscription) { - this._dispose(); - } - }; - AsyncPipe.prototype.transform = function (obj) { - if (!this._obj) { - if (obj) { - this._subscribe(obj); - } - this._latestReturnedValue = this._latestValue; - return this._latestValue; - } - if (obj !== this._obj) { - this._dispose(); - return this.transform(obj); - } - if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵlooseIdentical"])(this._latestValue, this._latestReturnedValue)) { - return this._latestReturnedValue; - } - this._latestReturnedValue = this._latestValue; - return _angular_core__WEBPACK_IMPORTED_MODULE_0__["WrappedValue"].wrap(this._latestValue); - }; - AsyncPipe.prototype._subscribe = function (obj) { - var _this = this; - this._obj = obj; - this._strategy = this._selectStrategy(obj); - this._subscription = this._strategy.createSubscription(obj, function (value) { return _this._updateLatestValue(obj, value); }); - }; - AsyncPipe.prototype._selectStrategy = function (obj) { - if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisPromise"])(obj)) { - return _promiseStrategy; - } - if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisObservable"])(obj)) { - return _observableStrategy; - } - throw invalidPipeArgumentError(AsyncPipe_1, obj); - }; - AsyncPipe.prototype._dispose = function () { - this._strategy.dispose(this._subscription); - this._latestValue = null; - this._latestReturnedValue = null; - this._subscription = null; - this._obj = null; - }; - AsyncPipe.prototype._updateLatestValue = function (async, value) { - if (async === this._obj) { - this._latestValue = value; - this._ref.markForCheck(); - } - }; - var AsyncPipe_1; - AsyncPipe = AsyncPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'async', pure: false }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]]) - ], AsyncPipe); - return AsyncPipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Transforms text to all lower case. - * - * @see `UpperCasePipe` - * @see `TitleCasePipe` - * @usageNotes - * - * The following example defines a view that allows the user to enter - * text, and then uses the pipe to convert the input text to all lower case. - * - * - * - * @ngModule CommonModule - * @publicApi - */ -var LowerCasePipe = /** @class */ (function () { - function LowerCasePipe() { - } - LowerCasePipe_1 = LowerCasePipe; - /** - * @param value The string to transform to lower case. - */ - LowerCasePipe.prototype.transform = function (value) { - if (!value) - return value; - if (typeof value !== 'string') { - throw invalidPipeArgumentError(LowerCasePipe_1, value); - } - return value.toLowerCase(); - }; - var LowerCasePipe_1; - LowerCasePipe = LowerCasePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'lowercase' }) - ], LowerCasePipe); - return LowerCasePipe; -}()); -// -// Regex below matches any Unicode word and compatible with ES5. In ES2018 the same result -// can be achieved by using /\p{L}\S*/gu and also known as Unicode Property Escapes -// (http://2ality.com/2017/07/regexp-unicode-property-escapes.html). Since there is no -// transpilation of this functionality down to ES5 without external tool, the only solution is -// to use already transpiled form. Example can be found here - -// https://mothereff.in/regexpu#input=var+regex+%3D+/%5Cp%7BL%7D/u%3B&unicodePropertyEscape=1 -// -var unicodeWordMatch = /(?:[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\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EE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D])\S*/g; -/** - * Transforms text to title case. - * Capitalizes the first letter of each word, and transforms the - * rest of the word to lower case. - * Words are delimited by any whitespace character, such as a space, tab, or line-feed character. - * - * @see `LowerCasePipe` - * @see `UpperCasePipe` - * - * @usageNotes - * The following example shows the result of transforming various strings into title case. - * - * - * - * @ngModule CommonModule - * @publicApi - */ -var TitleCasePipe = /** @class */ (function () { - function TitleCasePipe() { - } - TitleCasePipe_1 = TitleCasePipe; - /** - * @param value The string to transform to title case. - */ - TitleCasePipe.prototype.transform = function (value) { - if (!value) - return value; - if (typeof value !== 'string') { - throw invalidPipeArgumentError(TitleCasePipe_1, value); - } - return value.replace(unicodeWordMatch, (function (txt) { return txt[0].toUpperCase() + txt.substr(1).toLowerCase(); })); - }; - var TitleCasePipe_1; - TitleCasePipe = TitleCasePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'titlecase' }) - ], TitleCasePipe); - return TitleCasePipe; -}()); -/** - * Transforms text to all upper case. - * @see `LowerCasePipe` - * @see `TitleCasePipe` - * - * @ngModule CommonModule - * @publicApi - */ -var UpperCasePipe = /** @class */ (function () { - function UpperCasePipe() { - } - UpperCasePipe_1 = UpperCasePipe; - /** - * @param value The string to transform to upper case. - */ - UpperCasePipe.prototype.transform = function (value) { - if (!value) - return value; - if (typeof value !== 'string') { - throw invalidPipeArgumentError(UpperCasePipe_1, value); - } - return value.toUpperCase(); - }; - var UpperCasePipe_1; - UpperCasePipe = UpperCasePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'uppercase' }) - ], UpperCasePipe); - return UpperCasePipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// clang-format off -/** - * @ngModule CommonModule - * @description - * - * Formats a date value according to locale rules. - * - * Only the `en-US` locale data comes with Angular. To localize dates - * in another language, you must import the corresponding locale data. - * See the [I18n guide](guide/i18n#i18n-pipes) for more information. - * - * @see `formatDate()` - * - * - * @usageNotes - * - * The result of this pipe is not reevaluated when the input is mutated. To avoid the need to - * reformat the date on every change-detection cycle, treat the date as an immutable object - * and change the reference when the pipe needs to run again. - * - * ### Pre-defined format options - * - * Examples are given in `en-US` locale. - * - * - `'short'`: equivalent to `'M/d/yy, h:mm a'` (`6/15/15, 9:03 AM`). - * - `'medium'`: equivalent to `'MMM d, y, h:mm:ss a'` (`Jun 15, 2015, 9:03:01 AM`). - * - `'long'`: equivalent to `'MMMM d, y, h:mm:ss a z'` (`June 15, 2015 at 9:03:01 AM - * GMT+1`). - * - `'full'`: equivalent to `'EEEE, MMMM d, y, h:mm:ss a zzzz'` (`Monday, June 15, 2015 at - * 9:03:01 AM GMT+01:00`). - * - `'shortDate'`: equivalent to `'M/d/yy'` (`6/15/15`). - * - `'mediumDate'`: equivalent to `'MMM d, y'` (`Jun 15, 2015`). - * - `'longDate'`: equivalent to `'MMMM d, y'` (`June 15, 2015`). - * - `'fullDate'`: equivalent to `'EEEE, MMMM d, y'` (`Monday, June 15, 2015`). - * - `'shortTime'`: equivalent to `'h:mm a'` (`9:03 AM`). - * - `'mediumTime'`: equivalent to `'h:mm:ss a'` (`9:03:01 AM`). - * - `'longTime'`: equivalent to `'h:mm:ss a z'` (`9:03:01 AM GMT+1`). - * - `'fullTime'`: equivalent to `'h:mm:ss a zzzz'` (`9:03:01 AM GMT+01:00`). - * - * ### Custom format options - * - * You can construct a format string using symbols to specify the components - * of a date-time value, as described in the following table. - * Format details depend on the locale. - * Fields marked with (*) are only available in the extra data set for the given locale. - * - * | Field type | Format | Description | Example Value | - * |--------------------|-------------|---------------------------------------------------------------|------------------------------------------------------------| - * | Era | G, GG & GGG | Abbreviated | AD | - * | | GGGG | Wide | Anno Domini | - * | | GGGGG | Narrow | A | - * | Year | y | Numeric: minimum digits | 2, 20, 201, 2017, 20173 | - * | | yy | Numeric: 2 digits + zero padded | 02, 20, 01, 17, 73 | - * | | yyy | Numeric: 3 digits + zero padded | 002, 020, 201, 2017, 20173 | - * | | yyyy | Numeric: 4 digits or more + zero padded | 0002, 0020, 0201, 2017, 20173 | - * | Month | M | Numeric: 1 digit | 9, 12 | - * | | MM | Numeric: 2 digits + zero padded | 09, 12 | - * | | MMM | Abbreviated | Sep | - * | | MMMM | Wide | September | - * | | MMMMM | Narrow | S | - * | Month standalone | L | Numeric: 1 digit | 9, 12 | - * | | LL | Numeric: 2 digits + zero padded | 09, 12 | - * | | LLL | Abbreviated | Sep | - * | | LLLL | Wide | September | - * | | LLLLL | Narrow | S | - * | Week of year | w | Numeric: minimum digits | 1... 53 | - * | | ww | Numeric: 2 digits + zero padded | 01... 53 | - * | Week of month | W | Numeric: 1 digit | 1... 5 | - * | Day of month | d | Numeric: minimum digits | 1 | - * | | dd | Numeric: 2 digits + zero padded | 01 | - * | Week day | E, EE & EEE | Abbreviated | Tue | - * | | EEEE | Wide | Tuesday | - * | | EEEEE | Narrow | T | - * | | EEEEEE | Short | Tu | - * | Period | a, aa & aaa | Abbreviated | am/pm or AM/PM | - * | | aaaa | Wide (fallback to `a` when missing) | ante meridiem/post meridiem | - * | | aaaaa | Narrow | a/p | - * | Period* | B, BB & BBB | Abbreviated | mid. | - * | | BBBB | Wide | am, pm, midnight, noon, morning, afternoon, evening, night | - * | | BBBBB | Narrow | md | - * | Period standalone* | b, bb & bbb | Abbreviated | mid. | - * | | bbbb | Wide | am, pm, midnight, noon, morning, afternoon, evening, night | - * | | bbbbb | Narrow | md | - * | Hour 1-12 | h | Numeric: minimum digits | 1, 12 | - * | | hh | Numeric: 2 digits + zero padded | 01, 12 | - * | Hour 0-23 | H | Numeric: minimum digits | 0, 23 | - * | | HH | Numeric: 2 digits + zero padded | 00, 23 | - * | Minute | m | Numeric: minimum digits | 8, 59 | - * | | mm | Numeric: 2 digits + zero padded | 08, 59 | - * | Second | s | Numeric: minimum digits | 0... 59 | - * | | ss | Numeric: 2 digits + zero padded | 00... 59 | - * | Fractional seconds | S | Numeric: 1 digit | 0... 9 | - * | | SS | Numeric: 2 digits + zero padded | 00... 99 | - * | | SSS | Numeric: 3 digits + zero padded (= milliseconds) | 000... 999 | - * | Zone | z, zz & zzz | Short specific non location format (fallback to O) | GMT-8 | - * | | zzzz | Long specific non location format (fallback to OOOO) | GMT-08:00 | - * | | Z, ZZ & ZZZ | ISO8601 basic format | -0800 | - * | | ZZZZ | Long localized GMT format | GMT-8:00 | - * | | ZZZZZ | ISO8601 extended format + Z indicator for offset 0 (= XXXXX) | -08:00 | - * | | O, OO & OOO | Short localized GMT format | GMT-8 | - * | | OOOO | Long localized GMT format | GMT-08:00 | - * - * Note that timezone correction is not applied to an ISO string that has no time component, such as "2016-09-19" - * - * ### Format examples - * - * These examples transform a date into various formats, - * assuming that `dateObj` is a JavaScript `Date` object for - * year: 2015, month: 6, day: 15, hour: 21, minute: 43, second: 11, - * given in the local time for the `en-US` locale. - * - * ``` - * {{ dateObj | date }} // output is 'Jun 15, 2015' - * {{ dateObj | date:'medium' }} // output is 'Jun 15, 2015, 9:43:11 PM' - * {{ dateObj | date:'shortTime' }} // output is '9:43 PM' - * {{ dateObj | date:'mm:ss' }} // output is '43:11' - * ``` - * - * ### Usage example - * - * The following component uses a date pipe to display the current date in different formats. - * - * ``` - * @Component({ - * selector: 'date-pipe', - * template: `
    - *

    Today is {{today | date}}

    - *

    Or if you prefer, {{today | date:'fullDate'}}

    - *

    The time is {{today | date:'h:mm a z'}}

    - *
    ` - * }) - * // Get the current date and time as a date-time value. - * export class DatePipeComponent { - * today: number = Date.now(); - * } - * ``` - * - * @publicApi - */ -// clang-format on -var DatePipe = /** @class */ (function () { - function DatePipe(locale) { - this.locale = locale; - } - DatePipe_1 = DatePipe; - /** - * @param value The date expression: a `Date` object, a number - * (milliseconds since UTC epoch), or an ISO string (https://www.w3.org/TR/NOTE-datetime). - * @param format The date/time components to include, using predefined options or a - * custom format string. - * @param timezone A timezone offset (such as `'+0430'`), or a standard - * UTC/GMT or continental US timezone abbreviation. - * When not supplied, uses the end-user's local system timezone. - * @param locale A locale code for the locale format rules to use. - * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default. - * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app). - * @returns A date string in the desired format. - */ - DatePipe.prototype.transform = function (value, format, timezone, locale) { - if (format === void 0) { format = 'mediumDate'; } - if (value == null || value === '' || value !== value) - return null; - try { - return formatDate(value, format, locale || this.locale, timezone); - } - catch (error) { - throw invalidPipeArgumentError(DatePipe_1, error.message); - } - }; - var DatePipe_1; - DatePipe = DatePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'date', pure: true }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DatePipe); - return DatePipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _INTERPOLATION_REGEXP = /#/g; -/** - * @ngModule CommonModule - * @description - * - * Maps a value to a string that pluralizes the value according to locale rules. - * - * @usageNotes - * - * ### Example - * - * {@example common/pipes/ts/i18n_pipe.ts region='I18nPluralPipeComponent'} - * - * @publicApi - */ -var I18nPluralPipe = /** @class */ (function () { - function I18nPluralPipe(_localization) { - this._localization = _localization; - } - I18nPluralPipe_1 = I18nPluralPipe; - /** - * @param value the number to be formatted - * @param pluralMap an object that mimics the ICU format, see - * http://userguide.icu-project.org/formatparse/messages. - * @param locale a `string` defining the locale to use (uses the current {@link LOCALE_ID} by - * default). - */ - I18nPluralPipe.prototype.transform = function (value, pluralMap, locale) { - if (value == null) - return ''; - if (typeof pluralMap !== 'object' || pluralMap === null) { - throw invalidPipeArgumentError(I18nPluralPipe_1, pluralMap); - } - var key = getPluralCategory(value, Object.keys(pluralMap), this._localization, locale); - return pluralMap[key].replace(_INTERPOLATION_REGEXP, value.toString()); - }; - var I18nPluralPipe_1; - I18nPluralPipe = I18nPluralPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'i18nPlural', pure: true }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [NgLocalization]) - ], I18nPluralPipe); - return I18nPluralPipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * @description - * - * Generic selector that displays the string that matches the current value. - * - * If none of the keys of the `mapping` match the `value`, then the content - * of the `other` key is returned when present, otherwise an empty string is returned. - * - * @usageNotes - * - * ### Example - * - * {@example common/pipes/ts/i18n_pipe.ts region='I18nSelectPipeComponent'} - * - * @publicApi - */ -var I18nSelectPipe = /** @class */ (function () { - function I18nSelectPipe() { - } - I18nSelectPipe_1 = I18nSelectPipe; - /** - * @param value a string to be internationalized. - * @param mapping an object that indicates the text that should be displayed - * for different values of the provided `value`. - */ - I18nSelectPipe.prototype.transform = function (value, mapping) { - if (value == null) - return ''; - if (typeof mapping !== 'object' || typeof value !== 'string') { - throw invalidPipeArgumentError(I18nSelectPipe_1, mapping); - } - if (mapping.hasOwnProperty(value)) { - return mapping[value]; - } - if (mapping.hasOwnProperty('other')) { - return mapping['other']; - } - return ''; - }; - var I18nSelectPipe_1; - I18nSelectPipe = I18nSelectPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'i18nSelect', pure: true }) - ], I18nSelectPipe); - return I18nSelectPipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * @description - * - * Converts a value into its JSON-format representation. Useful for debugging. - * - * @usageNotes - * - * The following component uses a JSON pipe to convert an object - * to JSON format, and displays the string in both formats for comparison. - * - * {@example common/pipes/ts/json_pipe.ts region='JsonPipe'} - * - * @publicApi - */ -var JsonPipe = /** @class */ (function () { - function JsonPipe() { - } - /** - * @param value A value of any type to convert into a JSON-format string. - */ - JsonPipe.prototype.transform = function (value) { return JSON.stringify(value, null, 2); }; - JsonPipe = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'json', pure: false }) - ], JsonPipe); - return JsonPipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function makeKeyValuePair(key, value) { - return { key: key, value: value }; -} -/** - * @ngModule CommonModule - * @description - * - * Transforms Object or Map into an array of key value pairs. - * - * The output array will be ordered by keys. - * By default the comparator will be by Unicode point value. - * You can optionally pass a compareFn if your keys are complex types. - * - * @usageNotes - * ### Examples - * - * This examples show how an Object or a Map can be iterated by ngFor with the use of this keyvalue - * pipe. - * - * {@example common/pipes/ts/keyvalue_pipe.ts region='KeyValuePipe'} - * - * @publicApi - */ -var KeyValuePipe = /** @class */ (function () { - function KeyValuePipe(differs) { - this.differs = differs; - this.keyValues = []; - } - KeyValuePipe.prototype.transform = function (input, compareFn) { - var _this = this; - if (compareFn === void 0) { compareFn = defaultComparator; } - if (!input || (!(input instanceof Map) && typeof input !== 'object')) { - return null; - } - if (!this.differ) { - // make a differ for whatever type we've been passed in - this.differ = this.differs.find(input).create(); - } - var differChanges = this.differ.diff(input); - if (differChanges) { - this.keyValues = []; - differChanges.forEachItem(function (r) { - _this.keyValues.push(makeKeyValuePair(r.key, r.currentValue)); - }); - this.keyValues.sort(compareFn); - } - return this.keyValues; - }; - KeyValuePipe = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'keyvalue', pure: false }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [_angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]]) - ], KeyValuePipe); - return KeyValuePipe; -}()); -function defaultComparator(keyValueA, keyValueB) { - var a = keyValueA.key; - var b = keyValueB.key; - // if same exit with 0; - if (a === b) - return 0; - // make sure that undefined are at the end of the sort. - if (a === undefined) - return 1; - if (b === undefined) - return -1; - // make sure that nulls are at the end of the sort. - if (a === null) - return 1; - if (b === null) - return -1; - if (typeof a == 'string' && typeof b == 'string') { - return a < b ? -1 : 1; - } - if (typeof a == 'number' && typeof b == 'number') { - return a - b; - } - if (typeof a == 'boolean' && typeof b == 'boolean') { - return a < b ? -1 : 1; - } - // `a` and `b` are of different types. Compare their string values. - var aString = String(a); - var bString = String(b); - return aString == bString ? 0 : aString < bString ? -1 : 1; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * @description - * - * Transforms a number into a string, - * formatted according to locale rules that determine group sizing and - * separator, decimal-point character, and other locale-specific - * configurations. - * - * If no parameters are specified, the function rounds off to the nearest value using this - * [rounding method](https://en.wikibooks.org/wiki/Arithmetic/Rounding). - * The behavior differs from that of the JavaScript ```Math.round()``` function. - * In the following case for example, the pipe rounds down where - * ```Math.round()``` rounds up: - * - * ```html - * -2.5 | number:'1.0-0' - * > -3 - * Math.round(-2.5) - * > -2 - * ``` - * - * @see `formatNumber()` - * - * @usageNotes - * The following code shows how the pipe transforms numbers - * into text strings, according to various format specifications, - * where the caller's default locale is `en-US`. - * - * ### Example - * - * - * - * @publicApi - */ -var DecimalPipe = /** @class */ (function () { - function DecimalPipe(_locale) { - this._locale = _locale; - } - DecimalPipe_1 = DecimalPipe; - /** - * @param value The number to be formatted. - * @param digitsInfo Decimal representation options, specified by a string - * in the following format:
    - * {minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}. - * - `minIntegerDigits`: The minimum number of integer digits before the decimal point. - * Default is `1`. - * - `minFractionDigits`: The minimum number of digits after the decimal point. - * Default is `0`. - * - `maxFractionDigits`: The maximum number of digits after the decimal point. - * Default is `3`. - * @param locale A locale code for the locale format rules to use. - * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default. - * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app). - */ - DecimalPipe.prototype.transform = function (value, digitsInfo, locale) { - if (isEmpty(value)) - return null; - locale = locale || this._locale; - try { - var num = strToNumber(value); - return formatNumber(num, locale, digitsInfo); - } - catch (error) { - throw invalidPipeArgumentError(DecimalPipe_1, error.message); - } - }; - var DecimalPipe_1; - DecimalPipe = DecimalPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'number' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], DecimalPipe); - return DecimalPipe; -}()); -/** - * @ngModule CommonModule - * @description - * - * Transforms a number to a percentage - * string, formatted according to locale rules that determine group sizing and - * separator, decimal-point character, and other locale-specific - * configurations. - * - * @see `formatPercent()` - * - * @usageNotes - * The following code shows how the pipe transforms numbers - * into text strings, according to various format specifications, - * where the caller's default locale is `en-US`. - * - * - * - * @publicApi - */ -var PercentPipe = /** @class */ (function () { - function PercentPipe(_locale) { - this._locale = _locale; - } - PercentPipe_1 = PercentPipe; - /** - * - * @param value The number to be formatted as a percentage. - * @param digitsInfo Decimal representation options, specified by a string - * in the following format:
    - * {minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}. - * - `minIntegerDigits`: The minimum number of integer digits before the decimal point. - * Default is `1`. - * - `minFractionDigits`: The minimum number of digits after the decimal point. - * Default is `0`. - * - `maxFractionDigits`: The maximum number of digits after the decimal point. - * Default is `0`. - * @param locale A locale code for the locale format rules to use. - * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default. - * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app). - */ - PercentPipe.prototype.transform = function (value, digitsInfo, locale) { - if (isEmpty(value)) - return null; - locale = locale || this._locale; - try { - var num = strToNumber(value); - return formatPercent(num, locale, digitsInfo); - } - catch (error) { - throw invalidPipeArgumentError(PercentPipe_1, error.message); - } - }; - var PercentPipe_1; - PercentPipe = PercentPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'percent' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], PercentPipe); - return PercentPipe; -}()); -/** - * @ngModule CommonModule - * @description - * - * Transforms a number to a currency string, formatted according to locale rules - * that determine group sizing and separator, decimal-point character, - * and other locale-specific configurations. - * - * @see `getCurrencySymbol()` - * @see `formatCurrency()` - * - * @usageNotes - * The following code shows how the pipe transforms numbers - * into text strings, according to various format specifications, - * where the caller's default locale is `en-US`. - * - * - * - * @publicApi - */ -var CurrencyPipe = /** @class */ (function () { - function CurrencyPipe(_locale) { - this._locale = _locale; - } - CurrencyPipe_1 = CurrencyPipe; - /** - * - * @param value The number to be formatted as currency. - * @param currencyCode The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code, - * such as `USD` for the US dollar and `EUR` for the euro. - * @param display The format for the currency indicator. One of the following: - * - `code`: Show the code (such as `USD`). - * - `symbol`(default): Show the symbol (such as `$`). - * - `symbol-narrow`: Use the narrow symbol for locales that have two symbols for their - * currency. - * For example, the Canadian dollar CAD has the symbol `CA$` and the symbol-narrow `$`. If the - * locale has no narrow symbol, uses the standard symbol for the locale. - * - String: Use the given string value instead of a code or a symbol. - * For example, an empty string will suppress the currency & symbol. - * - Boolean (marked deprecated in v5): `true` for symbol and false for `code`. - * - * @param digitsInfo Decimal representation options, specified by a string - * in the following format:
    - * {minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}. - * - `minIntegerDigits`: The minimum number of integer digits before the decimal point. - * Default is `1`. - * - `minFractionDigits`: The minimum number of digits after the decimal point. - * Default is `2`. - * - `maxFractionDigits`: The maximum number of digits after the decimal point. - * Default is `2`. - * If not provided, the number will be formatted with the proper amount of digits, - * depending on what the [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) specifies. - * For example, the Canadian dollar has 2 digits, whereas the Chilean peso has none. - * @param locale A locale code for the locale format rules to use. - * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default. - * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app). - */ - CurrencyPipe.prototype.transform = function (value, currencyCode, display, digitsInfo, locale) { - if (display === void 0) { display = 'symbol'; } - if (isEmpty(value)) - return null; - locale = locale || this._locale; - if (typeof display === 'boolean') { - if (console && console.warn) { - console.warn("Warning: the currency pipe has been changed in Angular v5. The symbolDisplay option (third parameter) is now a string instead of a boolean. The accepted values are \"code\", \"symbol\" or \"symbol-narrow\"."); - } - display = display ? 'symbol' : 'code'; - } - var currency = currencyCode || 'USD'; - if (display !== 'code') { - if (display === 'symbol' || display === 'symbol-narrow') { - currency = getCurrencySymbol(currency, display === 'symbol' ? 'wide' : 'narrow', locale); - } - else { - currency = display; - } - } - try { - var num = strToNumber(value); - return formatCurrency(num, locale, currency, currencyCode, digitsInfo); - } - catch (error) { - throw invalidPipeArgumentError(CurrencyPipe_1, error.message); - } - }; - var CurrencyPipe_1; - CurrencyPipe = CurrencyPipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'currency' }), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__param"])(0, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"])), - Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__metadata"])("design:paramtypes", [String]) - ], CurrencyPipe); - return CurrencyPipe; -}()); -function isEmpty(value) { - return value == null || value === '' || value !== value; -} -/** - * Transforms a string into a number (if needed). - */ -function strToNumber(value) { - // Convert strings to numbers - if (typeof value === 'string' && !isNaN(Number(value) - parseFloat(value))) { - return Number(value); - } - if (typeof value !== 'number') { - throw new Error(value + " is not a number"); - } - return value; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @ngModule CommonModule - * @description - * - * Creates a new `Array` or `String` containing a subset (slice) of the elements. - * - * @usageNotes - * - * All behavior is based on the expected behavior of the JavaScript API `Array.prototype.slice()` - * and `String.prototype.slice()`. - * - * When operating on an `Array`, the returned `Array` is always a copy even when all - * the elements are being returned. - * - * When operating on a blank value, the pipe returns the blank value. - * - * ### List Example - * - * This `ngFor` example: - * - * {@example common/pipes/ts/slice_pipe.ts region='SlicePipe_list'} - * - * produces the following: - * - * ```html - *
  • b
  • - *
  • c
  • - * ``` - * - * ### String Examples - * - * {@example common/pipes/ts/slice_pipe.ts region='SlicePipe_string'} - * - * @publicApi - */ -var SlicePipe = /** @class */ (function () { - function SlicePipe() { - } - SlicePipe_1 = SlicePipe; - SlicePipe.prototype.transform = function (value, start, end) { - if (value == null) - return value; - if (!this.supports(value)) { - throw invalidPipeArgumentError(SlicePipe_1, value); - } - return value.slice(start, end); - }; - SlicePipe.prototype.supports = function (obj) { return typeof obj === 'string' || Array.isArray(obj); }; - var SlicePipe_1; - SlicePipe = SlicePipe_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"])(), - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"])({ name: 'slice', pure: false }) - ], SlicePipe); - return SlicePipe; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A collection of Angular pipes that are likely to be used in each and every application. - */ -var COMMON_PIPES = [ - AsyncPipe, - UpperCasePipe, - LowerCasePipe, - JsonPipe, - SlicePipe, - DecimalPipe, - PercentPipe, - TitleCasePipe, - CurrencyPipe, - DatePipe, - I18nPluralPipe, - I18nSelectPipe, - KeyValuePipe, -]; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// Note: This does not contain the location providers, -// as they need some platform specific implementations to work. -/** - * Exports all the basic Angular directives and pipes, - * such as `NgIf`, `NgForOf`, `DecimalPipe`, and so on. - * Re-exported by `BrowserModule`, which is included automatically in the root - * `AppModule` when you create a new app with the CLI `new` command. - * - * * The `providers` options configure the NgModule's injector to provide - * localization dependencies to members. - * * The `exports` options make the declared directives and pipes available for import - * by other NgModules. - * - * @publicApi - */ -var CommonModule = /** @class */ (function () { - function CommonModule() { - } - CommonModule = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({ - declarations: [COMMON_DIRECTIVES, COMMON_PIPES], - exports: [COMMON_DIRECTIVES, COMMON_PIPES], - providers: [ - { provide: NgLocalization, useClass: NgLocaleLocalization }, - ], - }) - ], CommonModule); - return CommonModule; -}()); -var ɵ0$2 = getPluralCase; -/** - * A module that contains the deprecated i18n pipes. - * - * @deprecated from v5 - * @publicApi - */ -var DeprecatedI18NPipesModule = /** @class */ (function () { - function DeprecatedI18NPipesModule() { - } - DeprecatedI18NPipesModule = Object(tslib__WEBPACK_IMPORTED_MODULE_1__["__decorate"])([ - Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({ - declarations: [COMMON_DEPRECATED_I18N_PIPES], - exports: [COMMON_DEPRECATED_I18N_PIPES], - providers: [{ provide: DEPRECATED_PLURAL_FN, useValue: ɵ0$2 }], - }) - ], DeprecatedI18NPipesModule); - return DeprecatedI18NPipesModule; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A DI Token representing the main rendering context. In a browser this is the DOM Document. - * - * Note: Document might not be available in the Application Context when Application and Rendering - * Contexts are not the same (e.g. when running the application into a Web Worker). - * - * @publicApi - */ -var DOCUMENT = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('DocumentToken'); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var PLATFORM_BROWSER_ID = 'browser'; -var PLATFORM_SERVER_ID = 'server'; -var PLATFORM_WORKER_APP_ID = 'browserWorkerApp'; -var PLATFORM_WORKER_UI_ID = 'browserWorkerUi'; -/** - * Returns whether a platform id represents a browser platform. - * @publicApi - */ -function isPlatformBrowser(platformId) { - return platformId === PLATFORM_BROWSER_ID; -} -/** - * Returns whether a platform id represents a server platform. - * @publicApi - */ -function isPlatformServer(platformId) { - return platformId === PLATFORM_SERVER_ID; -} -/** - * Returns whether a platform id represents a web worker app platform. - * @publicApi - */ -function isPlatformWorkerApp(platformId) { - return platformId === PLATFORM_WORKER_APP_ID; -} -/** - * Returns whether a platform id represents a web worker UI platform. - * @publicApi - */ -function isPlatformWorkerUi(platformId) { - return platformId === PLATFORM_WORKER_UI_ID; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * @publicApi - */ -var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('8.2.8'); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Defines a scroll position manager. Implemented by `BrowserViewportScroller`. - * - * @publicApi - */ -var ViewportScroller = /** @class */ (function () { - function ViewportScroller() { - } - // De-sugared tree-shakable injection - // See #23917 - /** @nocollapse */ - ViewportScroller.ngInjectableDef = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({ - token: ViewportScroller, - providedIn: 'root', - factory: function () { return new BrowserViewportScroller(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(DOCUMENT), window, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ErrorHandler"])); } - }); - return ViewportScroller; -}()); -/** - * Manages the scroll position for a browser window. - */ -var BrowserViewportScroller = /** @class */ (function () { - function BrowserViewportScroller(document, window, errorHandler) { - this.document = document; - this.window = window; - this.errorHandler = errorHandler; - this.offset = function () { return [0, 0]; }; - } - /** - * Configures the top offset used when scrolling to an anchor. - * @param offset A position in screen coordinates (a tuple with x and y values) - * or a function that returns the top offset position. - * - */ - BrowserViewportScroller.prototype.setOffset = function (offset) { - if (Array.isArray(offset)) { - this.offset = function () { return offset; }; - } - else { - this.offset = offset; - } - }; - /** - * Retrieves the current scroll position. - * @returns The position in screen coordinates. - */ - BrowserViewportScroller.prototype.getScrollPosition = function () { - if (this.supportScrollRestoration()) { - return [this.window.scrollX, this.window.scrollY]; - } - else { - return [0, 0]; - } - }; - /** - * Sets the scroll position. - * @param position The new position in screen coordinates. - */ - BrowserViewportScroller.prototype.scrollToPosition = function (position) { - if (this.supportScrollRestoration()) { - this.window.scrollTo(position[0], position[1]); - } - }; - /** - * Scrolls to an anchor element. - * @param anchor The ID of the anchor element. - */ - BrowserViewportScroller.prototype.scrollToAnchor = function (anchor) { - if (this.supportScrollRestoration()) { - // Escape anything passed to `querySelector` as it can throw errors and stop the application - // from working if invalid values are passed. - if (this.window.CSS && this.window.CSS.escape) { - anchor = this.window.CSS.escape(anchor); - } - else { - anchor = anchor.replace(/(\"|\'\ |:|\.|\[|\]|,|=)/g, '\\$1'); - } - try { - var elSelectedById = this.document.querySelector("#" + anchor); - if (elSelectedById) { - this.scrollToElement(elSelectedById); - return; - } - var elSelectedByName = this.document.querySelector("[name='" + anchor + "']"); - if (elSelectedByName) { - this.scrollToElement(elSelectedByName); - return; - } - } - catch (e) { - this.errorHandler.handleError(e); - } - } - }; - /** - * Disables automatic scroll restoration provided by the browser. - */ - BrowserViewportScroller.prototype.setHistoryScrollRestoration = function (scrollRestoration) { - if (this.supportScrollRestoration()) { - var history_1 = this.window.history; - if (history_1 && history_1.scrollRestoration) { - history_1.scrollRestoration = scrollRestoration; - } - } - }; - BrowserViewportScroller.prototype.scrollToElement = function (el) { - var rect = el.getBoundingClientRect(); - var left = rect.left + this.window.pageXOffset; - var top = rect.top + this.window.pageYOffset; - var offset = this.offset(); - this.window.scrollTo(left - offset[0], top - offset[1]); - }; - /** - * We only support scroll restoration when we can get a hold of window. - * This means that we do not support this behavior when running in a web worker. - * - * Lifting this restriction right now would require more changes in the dom adapter. - * Since webworkers aren't widely used, we will lift it once RouterScroller is - * battle-tested. - */ - BrowserViewportScroller.prototype.supportScrollRestoration = function () { - try { - return !!this.window && !!this.window.scrollTo; - } - catch (_a) { - return false; - } - }; - return BrowserViewportScroller; -}()); -/** - * Provides an empty implementation of the viewport scroller. This will - * live in @angular/common as it will be used by both platform-server and platform-webworker. - */ -var NullViewportScroller = /** @class */ (function () { - function NullViewportScroller() { - } - /** - * Empty implementation - */ - NullViewportScroller.prototype.setOffset = function (offset) { }; - /** - * Empty implementation - */ - NullViewportScroller.prototype.getScrollPosition = function () { return [0, 0]; }; - /** - * Empty implementation - */ - NullViewportScroller.prototype.scrollToPosition = function (position) { }; - /** - * Empty implementation - */ - NullViewportScroller.prototype.scrollToAnchor = function (anchor) { }; - /** - * Empty implementation - */ - NullViewportScroller.prototype.setHistoryScrollRestoration = function (scrollRestoration) { }; - return NullViewportScroller; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// This file only reexports content of the `src` folder. Keep it that way. - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ - -/** - * Generated bundle index. Do not edit. - */ - - -//# sourceMappingURL=common.js.map - - -/***/ }), - -/***/ "../node_modules/@angular/compiler/fesm5/compiler.js": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* WEBPACK VAR INJECTION */(function(global) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "core", function() { return core; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompilerConfig", function() { return CompilerConfig; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "preserveWhitespacesDefault", function() { return preserveWhitespacesDefault; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isLoweredSymbol", function() { return isLoweredSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createLoweredSymbol", function() { return createLoweredSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Identifiers", function() { return Identifiers; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JitCompiler", function() { return JitCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ConstantPool", function() { return ConstantPool; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DirectiveResolver", function() { return DirectiveResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PipeResolver", function() { return PipeResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgModuleResolver", function() { return NgModuleResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DEFAULT_INTERPOLATION_CONFIG", function() { return DEFAULT_INTERPOLATION_CONFIG; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InterpolationConfig", function() { return InterpolationConfig; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgModuleCompiler", function() { return NgModuleCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ArrayType", function() { return ArrayType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AssertNotNull", function() { return AssertNotNull; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DYNAMIC_TYPE", function() { return DYNAMIC_TYPE; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BinaryOperator", function() { return BinaryOperator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BinaryOperatorExpr", function() { return BinaryOperatorExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BuiltinMethod", function() { return BuiltinMethod; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BuiltinType", function() { return BuiltinType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BuiltinTypeName", function() { return BuiltinTypeName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BuiltinVar", function() { return BuiltinVar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CastExpr", function() { return CastExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ClassField", function() { return ClassField; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ClassMethod", function() { return ClassMethod; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ClassStmt", function() { return ClassStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CommaExpr", function() { return CommaExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CommentStmt", function() { return CommentStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ConditionalExpr", function() { return ConditionalExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeclareFunctionStmt", function() { return DeclareFunctionStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DeclareVarStmt", function() { return DeclareVarStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Expression", function() { return Expression; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExpressionStatement", function() { return ExpressionStatement; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExpressionType", function() { return ExpressionType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExternalExpr", function() { return ExternalExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExternalReference", function() { return ExternalReference; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "literalMap", function() { return literalMap; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FunctionExpr", function() { return FunctionExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "IfStmt", function() { return IfStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InstantiateExpr", function() { return InstantiateExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InvokeFunctionExpr", function() { return InvokeFunctionExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InvokeMethodExpr", function() { return InvokeMethodExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JSDocCommentStmt", function() { return JSDocCommentStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralArrayExpr", function() { return LiteralArrayExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralExpr", function() { return LiteralExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralMapExpr", function() { return LiteralMapExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MapType", function() { return MapType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NotExpr", function() { return NotExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ReadKeyExpr", function() { return ReadKeyExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ReadPropExpr", function() { return ReadPropExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ReadVarExpr", function() { return ReadVarExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ReturnStatement", function() { return ReturnStatement; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ThrowStmt", function() { return ThrowStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TryCatchStmt", function() { return TryCatchStmt; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Type", function() { return Type$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WrappedNodeExpr", function() { return WrappedNodeExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WriteKeyExpr", function() { return WriteKeyExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WritePropExpr", function() { return WritePropExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WriteVarExpr", function() { return WriteVarExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StmtModifier", function() { return StmtModifier; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Statement", function() { return Statement; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "STRING_TYPE", function() { return STRING_TYPE; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TypeofExpr", function() { return TypeofExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "collectExternalReferences", function() { return collectExternalReferences; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EmitterVisitorContext", function() { return EmitterVisitorContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JitEvaluator", function() { return JitEvaluator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ViewCompiler", function() { return ViewCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "findStaticQueryIds", function() { return findStaticQueryIds; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "staticViewQueryIds", function() { return staticViewQueryIds; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getParseErrors", function() { return getParseErrors; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isSyntaxError", function() { return isSyntaxError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "syntaxError", function() { return syntaxError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Version", function() { return Version; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstBoundAttribute", function() { return BoundAttribute; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstBoundEvent", function() { return BoundEvent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstBoundText", function() { return BoundText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstContent", function() { return Content; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstElement", function() { return Element; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstRecursiveVisitor", function() { return RecursiveVisitor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstReference", function() { return Reference; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstTemplate", function() { return Template; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstText", function() { return Text; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstTextAttribute", function() { return TextAttribute; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TmplAstVariable", function() { return Variable; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "R3Identifiers", function() { return Identifiers$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "R3ResolvedDependencyType", function() { return R3ResolvedDependencyType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileInjector", function() { return compileInjector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileNgModule", function() { return compileNgModule; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compilePipeFromMetadata", function() { return compilePipeFromMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "makeBindingParser", function() { return makeBindingParser; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseTemplate", function() { return parseTemplate; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileBaseDefFromMetadata", function() { return compileBaseDefFromMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileComponentFromMetadata", function() { return compileComponentFromMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileDirectiveFromMetadata", function() { return compileDirectiveFromMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseHostBindings", function() { return parseHostBindings; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "verifyHostBindings", function() { return verifyHostBindings; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "publishFacade", function() { return publishFacade; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VERSION", function() { return VERSION$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TextAst", function() { return TextAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BoundTextAst", function() { return BoundTextAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AttrAst", function() { return AttrAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BoundElementPropertyAst", function() { return BoundElementPropertyAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BoundEventAst", function() { return BoundEventAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ReferenceAst", function() { return ReferenceAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VariableAst", function() { return VariableAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ElementAst", function() { return ElementAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EmbeddedTemplateAst", function() { return EmbeddedTemplateAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BoundDirectivePropertyAst", function() { return BoundDirectivePropertyAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DirectiveAst", function() { return DirectiveAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ProviderAst", function() { return ProviderAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ProviderAstType", function() { return ProviderAstType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgContentAst", function() { return NgContentAst; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NullTemplateVisitor", function() { return NullTemplateVisitor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RecursiveTemplateAstVisitor", function() { return RecursiveTemplateAstVisitor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "templateVisitAll", function() { return templateVisitAll; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sanitizeIdentifier", function() { return sanitizeIdentifier; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "identifierName", function() { return identifierName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "identifierModuleUrl", function() { return identifierModuleUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "viewClassName", function() { return viewClassName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rendererTypeName", function() { return rendererTypeName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hostViewClassName", function() { return hostViewClassName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "componentFactoryName", function() { return componentFactoryName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileSummaryKind", function() { return CompileSummaryKind; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tokenName", function() { return tokenName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tokenReference", function() { return tokenReference; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileStylesheetMetadata", function() { return CompileStylesheetMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileTemplateMetadata", function() { return CompileTemplateMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileDirectiveMetadata", function() { return CompileDirectiveMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompilePipeMetadata", function() { return CompilePipeMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileShallowModuleMetadata", function() { return CompileShallowModuleMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileNgModuleMetadata", function() { return CompileNgModuleMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransitiveCompileNgModuleMetadata", function() { return TransitiveCompileNgModuleMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ProviderMeta", function() { return ProviderMeta; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "flatten", function() { return flatten; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "templateSourceUrl", function() { return templateSourceUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sharedStylesheetJitUrl", function() { return sharedStylesheetJitUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ngModuleJitUrl", function() { return ngModuleJitUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "templateJitUrl", function() { return templateJitUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createAotUrlResolver", function() { return createAotUrlResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createAotCompiler", function() { return createAotCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AotCompiler", function() { return AotCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "analyzeNgModules", function() { return analyzeNgModules; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "analyzeAndValidateNgModules", function() { return analyzeAndValidateNgModules; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "analyzeFile", function() { return analyzeFile; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "analyzeFileForInjectables", function() { return analyzeFileForInjectables; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "mergeAnalyzedFiles", function() { return mergeAnalyzedFiles; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "GeneratedFile", function() { return GeneratedFile; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "toTypeScript", function() { return toTypeScript; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formattedError", function() { return formattedError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isFormattedError", function() { return isFormattedError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StaticReflector", function() { return StaticReflector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StaticSymbol", function() { return StaticSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StaticSymbolCache", function() { return StaticSymbolCache; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ResolvedStaticSymbol", function() { return ResolvedStaticSymbol; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StaticSymbolResolver", function() { return StaticSymbolResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "unescapeIdentifier", function() { return unescapeIdentifier; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "unwrapResolvedMetadata", function() { return unwrapResolvedMetadata; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AotSummaryResolver", function() { return AotSummaryResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AstPath", function() { return AstPath; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SummaryResolver", function() { return SummaryResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JitSummaryResolver", function() { return JitSummaryResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileReflector", function() { return CompileReflector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createUrlResolverWithoutPackagePrefix", function() { return createUrlResolverWithoutPackagePrefix; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createOfflineCompileUrlResolver", function() { return createOfflineCompileUrlResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlResolver", function() { return UrlResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getUrlScheme", function() { return getUrlScheme; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ResourceLoader", function() { return ResourceLoader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ElementSchemaRegistry", function() { return ElementSchemaRegistry; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Extractor", function() { return Extractor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "I18NHtmlParser", function() { return I18NHtmlParser; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MessageBundle", function() { return MessageBundle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Serializer", function() { return Serializer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Xliff", function() { return Xliff; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Xliff2", function() { return Xliff2; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Xmb", function() { return Xmb; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Xtb", function() { return Xtb; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DirectiveNormalizer", function() { return DirectiveNormalizer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParserError", function() { return ParserError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseSpan", function() { return ParseSpan; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AST", function() { return AST; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Quote", function() { return Quote; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EmptyExpr", function() { return EmptyExpr; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ImplicitReceiver", function() { return ImplicitReceiver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Chain", function() { return Chain; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Conditional", function() { return Conditional; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PropertyRead", function() { return PropertyRead; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PropertyWrite", function() { return PropertyWrite; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SafePropertyRead", function() { return SafePropertyRead; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "KeyedRead", function() { return KeyedRead; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "KeyedWrite", function() { return KeyedWrite; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BindingPipe", function() { return BindingPipe; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralPrimitive", function() { return LiteralPrimitive; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralArray", function() { return LiteralArray; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LiteralMap", function() { return LiteralMap; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Interpolation", function() { return Interpolation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Binary", function() { return Binary; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PrefixNot", function() { return PrefixNot; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NonNullAssert", function() { return NonNullAssert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MethodCall", function() { return MethodCall; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SafeMethodCall", function() { return SafeMethodCall; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FunctionCall", function() { return FunctionCall; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AbsoluteSourceSpan", function() { return AbsoluteSourceSpan; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ASTWithSource", function() { return ASTWithSource; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TemplateBinding", function() { return TemplateBinding; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NullAstVisitor", function() { return NullAstVisitor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RecursiveAstVisitor", function() { return RecursiveAstVisitor$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AstTransformer", function() { return AstTransformer$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AstMemoryEfficientTransformer", function() { return AstMemoryEfficientTransformer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "visitAstChildren", function() { return visitAstChildren; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParsedProperty", function() { return ParsedProperty; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParsedPropertyType", function() { return ParsedPropertyType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParsedEvent", function() { return ParsedEvent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParsedVariable", function() { return ParsedVariable; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BoundElementProperty", function() { return BoundElementProperty; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TokenType", function() { return TokenType$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Lexer", function() { return Lexer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Token", function() { return Token$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EOF", function() { return EOF; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isIdentifier", function() { return isIdentifier; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isQuote", function() { return isQuote; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SplitInterpolation", function() { return SplitInterpolation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TemplateBindingParseResult", function() { return TemplateBindingParseResult; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Parser", function() { return Parser$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "_ParseAST", function() { return _ParseAST; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ERROR_COMPONENT_TYPE", function() { return ERROR_COMPONENT_TYPE; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompileMetadataResolver", function() { return CompileMetadataResolver; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Text", function() { return Text$3; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Expansion", function() { return Expansion; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExpansionCase", function() { return ExpansionCase; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Attribute", function() { return Attribute; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Element", function() { return Element$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Comment", function() { return Comment; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "visitAll", function() { return visitAll$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RecursiveVisitor", function() { return RecursiveVisitor$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "findNode", function() { return findNode; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HtmlParser", function() { return HtmlParser; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseTreeResult", function() { return ParseTreeResult; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TreeError", function() { return TreeError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HtmlTagDefinition", function() { return HtmlTagDefinition; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getHtmlTagDefinition", function() { return getHtmlTagDefinition; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TagContentType", function() { return TagContentType; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "splitNsName", function() { return splitNsName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isNgContainer", function() { return isNgContainer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isNgContent", function() { return isNgContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isNgTemplate", function() { return isNgTemplate; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getNsPrefix", function() { return getNsPrefix; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "mergeNsAndName", function() { return mergeNsAndName; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NAMED_ENTITIES", function() { return NAMED_ENTITIES; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NGSP_UNICODE", function() { return NGSP_UNICODE; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "debugOutputAstAsTypeScript", function() { return debugOutputAstAsTypeScript; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TypeScriptEmitter", function() { return TypeScriptEmitter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseLocation", function() { return ParseLocation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseSourceFile", function() { return ParseSourceFile; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseSourceSpan", function() { return ParseSourceSpan; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EMPTY_PARSE_LOCATION", function() { return EMPTY_PARSE_LOCATION; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EMPTY_SOURCE_SPAN", function() { return EMPTY_SOURCE_SPAN; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseErrorLevel", function() { return ParseErrorLevel; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ParseError", function() { return ParseError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "typeSourceSpan", function() { return typeSourceSpan; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "r3JitTypeSourceSpan", function() { return r3JitTypeSourceSpan; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DomElementSchemaRegistry", function() { return DomElementSchemaRegistry; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CssSelector", function() { return CssSelector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SelectorMatcher", function() { return SelectorMatcher; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SelectorListContext", function() { return SelectorListContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SelectorContext", function() { return SelectorContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HOST_ATTR", function() { return HOST_ATTR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CONTENT_ATTR", function() { return CONTENT_ATTR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StylesCompileDependency", function() { return StylesCompileDependency; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CompiledStylesheet", function() { return CompiledStylesheet; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "StyleCompiler", function() { return StyleCompiler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TemplateParseError", function() { return TemplateParseError; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TemplateParseResult", function() { return TemplateParseResult; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TemplateParser", function() { return TemplateParser; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "splitClasses", function() { return splitClasses; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createElementCssSelector", function() { return createElementCssSelector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "removeSummaryDuplicates", function() { return removeSummaryDuplicates; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isEmptyExpression", function() { return isEmptyExpression; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compileInjectable", function() { return compileInjectable; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "R3TargetBinder", function() { return R3TargetBinder; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "R3BoundTarget", function() { return R3BoundTarget; }); -/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("../node_modules/tslib/tslib.es6.js"); -/** - * @license Angular v8.2.8 - * (c) 2010-2019 Google LLC. https://angular.io/ - * License: MIT - */ - - - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var TagContentType; -(function (TagContentType) { - TagContentType[TagContentType["RAW_TEXT"] = 0] = "RAW_TEXT"; - TagContentType[TagContentType["ESCAPABLE_RAW_TEXT"] = 1] = "ESCAPABLE_RAW_TEXT"; - TagContentType[TagContentType["PARSABLE_DATA"] = 2] = "PARSABLE_DATA"; -})(TagContentType || (TagContentType = {})); -function splitNsName(elementName) { - if (elementName[0] != ':') { - return [null, elementName]; - } - var colonIndex = elementName.indexOf(':', 1); - if (colonIndex == -1) { - throw new Error("Unsupported format \"" + elementName + "\" expecting \":namespace:name\""); - } - return [elementName.slice(1, colonIndex), elementName.slice(colonIndex + 1)]; -} -// `` tags work the same regardless the namespace -function isNgContainer(tagName) { - return splitNsName(tagName)[1] === 'ng-container'; -} -// `` tags work the same regardless the namespace -function isNgContent(tagName) { - return splitNsName(tagName)[1] === 'ng-content'; -} -// `` tags work the same regardless the namespace -function isNgTemplate(tagName) { - return splitNsName(tagName)[1] === 'ng-template'; -} -function getNsPrefix(fullName) { - return fullName === null ? null : splitNsName(fullName)[0]; -} -function mergeNsAndName(prefix, localName) { - return prefix ? ":" + prefix + ":" + localName : localName; -} -// see http://www.w3.org/TR/html51/syntax.html#named-character-references -// see https://html.spec.whatwg.org/multipage/entities.json -// This list is not exhaustive to keep the compiler footprint low. -// The `{` / `ƫ` syntax should be used when the named character reference does not -// exist. -var NAMED_ENTITIES = { - 'Aacute': '\u00C1', - 'aacute': '\u00E1', - 'Acirc': '\u00C2', - 'acirc': '\u00E2', - 'acute': '\u00B4', - 'AElig': '\u00C6', - 'aelig': '\u00E6', - 'Agrave': '\u00C0', - 'agrave': '\u00E0', - 'alefsym': '\u2135', - 'Alpha': '\u0391', - 'alpha': '\u03B1', - 'amp': '&', - 'and': '\u2227', - 'ang': '\u2220', - 'apos': '\u0027', - 'Aring': '\u00C5', - 'aring': '\u00E5', - 'asymp': '\u2248', - 'Atilde': '\u00C3', - 'atilde': '\u00E3', - 'Auml': '\u00C4', - 'auml': '\u00E4', - 'bdquo': '\u201E', - 'Beta': '\u0392', - 'beta': '\u03B2', - 'brvbar': '\u00A6', - 'bull': '\u2022', - 'cap': '\u2229', - 'Ccedil': '\u00C7', - 'ccedil': '\u00E7', - 'cedil': '\u00B8', - 'cent': '\u00A2', - 'Chi': '\u03A7', - 'chi': '\u03C7', - 'circ': '\u02C6', - 'clubs': '\u2663', - 'cong': '\u2245', - 'copy': '\u00A9', - 'crarr': '\u21B5', - 'cup': '\u222A', - 'curren': '\u00A4', - 'dagger': '\u2020', - 'Dagger': '\u2021', - 'darr': '\u2193', - 'dArr': '\u21D3', - 'deg': '\u00B0', - 'Delta': '\u0394', - 'delta': '\u03B4', - 'diams': '\u2666', - 'divide': '\u00F7', - 'Eacute': '\u00C9', - 'eacute': '\u00E9', - 'Ecirc': '\u00CA', - 'ecirc': '\u00EA', - 'Egrave': '\u00C8', - 'egrave': '\u00E8', - 'empty': '\u2205', - 'emsp': '\u2003', - 'ensp': '\u2002', - 'Epsilon': '\u0395', - 'epsilon': '\u03B5', - 'equiv': '\u2261', - 'Eta': '\u0397', - 'eta': '\u03B7', - 'ETH': '\u00D0', - 'eth': '\u00F0', - 'Euml': '\u00CB', - 'euml': '\u00EB', - 'euro': '\u20AC', - 'exist': '\u2203', - 'fnof': '\u0192', - 'forall': '\u2200', - 'frac12': '\u00BD', - 'frac14': '\u00BC', - 'frac34': '\u00BE', - 'frasl': '\u2044', - 'Gamma': '\u0393', - 'gamma': '\u03B3', - 'ge': '\u2265', - 'gt': '>', - 'harr': '\u2194', - 'hArr': '\u21D4', - 'hearts': '\u2665', - 'hellip': '\u2026', - 'Iacute': '\u00CD', - 'iacute': '\u00ED', - 'Icirc': '\u00CE', - 'icirc': '\u00EE', - 'iexcl': '\u00A1', - 'Igrave': '\u00CC', - 'igrave': '\u00EC', - 'image': '\u2111', - 'infin': '\u221E', - 'int': '\u222B', - 'Iota': '\u0399', - 'iota': '\u03B9', - 'iquest': '\u00BF', - 'isin': '\u2208', - 'Iuml': '\u00CF', - 'iuml': '\u00EF', - 'Kappa': '\u039A', - 'kappa': '\u03BA', - 'Lambda': '\u039B', - 'lambda': '\u03BB', - 'lang': '\u27E8', - 'laquo': '\u00AB', - 'larr': '\u2190', - 'lArr': '\u21D0', - 'lceil': '\u2308', - 'ldquo': '\u201C', - 'le': '\u2264', - 'lfloor': '\u230A', - 'lowast': '\u2217', - 'loz': '\u25CA', - 'lrm': '\u200E', - 'lsaquo': '\u2039', - 'lsquo': '\u2018', - 'lt': '<', - 'macr': '\u00AF', - 'mdash': '\u2014', - 'micro': '\u00B5', - 'middot': '\u00B7', - 'minus': '\u2212', - 'Mu': '\u039C', - 'mu': '\u03BC', - 'nabla': '\u2207', - 'nbsp': '\u00A0', - 'ndash': '\u2013', - 'ne': '\u2260', - 'ni': '\u220B', - 'not': '\u00AC', - 'notin': '\u2209', - 'nsub': '\u2284', - 'Ntilde': '\u00D1', - 'ntilde': '\u00F1', - 'Nu': '\u039D', - 'nu': '\u03BD', - 'Oacute': '\u00D3', - 'oacute': '\u00F3', - 'Ocirc': '\u00D4', - 'ocirc': '\u00F4', - 'OElig': '\u0152', - 'oelig': '\u0153', - 'Ograve': '\u00D2', - 'ograve': '\u00F2', - 'oline': '\u203E', - 'Omega': '\u03A9', - 'omega': '\u03C9', - 'Omicron': '\u039F', - 'omicron': '\u03BF', - 'oplus': '\u2295', - 'or': '\u2228', - 'ordf': '\u00AA', - 'ordm': '\u00BA', - 'Oslash': '\u00D8', - 'oslash': '\u00F8', - 'Otilde': '\u00D5', - 'otilde': '\u00F5', - 'otimes': '\u2297', - 'Ouml': '\u00D6', - 'ouml': '\u00F6', - 'para': '\u00B6', - 'permil': '\u2030', - 'perp': '\u22A5', - 'Phi': '\u03A6', - 'phi': '\u03C6', - 'Pi': '\u03A0', - 'pi': '\u03C0', - 'piv': '\u03D6', - 'plusmn': '\u00B1', - 'pound': '\u00A3', - 'prime': '\u2032', - 'Prime': '\u2033', - 'prod': '\u220F', - 'prop': '\u221D', - 'Psi': '\u03A8', - 'psi': '\u03C8', - 'quot': '\u0022', - 'radic': '\u221A', - 'rang': '\u27E9', - 'raquo': '\u00BB', - 'rarr': '\u2192', - 'rArr': '\u21D2', - 'rceil': '\u2309', - 'rdquo': '\u201D', - 'real': '\u211C', - 'reg': '\u00AE', - 'rfloor': '\u230B', - 'Rho': '\u03A1', - 'rho': '\u03C1', - 'rlm': '\u200F', - 'rsaquo': '\u203A', - 'rsquo': '\u2019', - 'sbquo': '\u201A', - 'Scaron': '\u0160', - 'scaron': '\u0161', - 'sdot': '\u22C5', - 'sect': '\u00A7', - 'shy': '\u00AD', - 'Sigma': '\u03A3', - 'sigma': '\u03C3', - 'sigmaf': '\u03C2', - 'sim': '\u223C', - 'spades': '\u2660', - 'sub': '\u2282', - 'sube': '\u2286', - 'sum': '\u2211', - 'sup': '\u2283', - 'sup1': '\u00B9', - 'sup2': '\u00B2', - 'sup3': '\u00B3', - 'supe': '\u2287', - 'szlig': '\u00DF', - 'Tau': '\u03A4', - 'tau': '\u03C4', - 'there4': '\u2234', - 'Theta': '\u0398', - 'theta': '\u03B8', - 'thetasym': '\u03D1', - 'thinsp': '\u2009', - 'THORN': '\u00DE', - 'thorn': '\u00FE', - 'tilde': '\u02DC', - 'times': '\u00D7', - 'trade': '\u2122', - 'Uacute': '\u00DA', - 'uacute': '\u00FA', - 'uarr': '\u2191', - 'uArr': '\u21D1', - 'Ucirc': '\u00DB', - 'ucirc': '\u00FB', - 'Ugrave': '\u00D9', - 'ugrave': '\u00F9', - 'uml': '\u00A8', - 'upsih': '\u03D2', - 'Upsilon': '\u03A5', - 'upsilon': '\u03C5', - 'Uuml': '\u00DC', - 'uuml': '\u00FC', - 'weierp': '\u2118', - 'Xi': '\u039E', - 'xi': '\u03BE', - 'Yacute': '\u00DD', - 'yacute': '\u00FD', - 'yen': '\u00A5', - 'yuml': '\u00FF', - 'Yuml': '\u0178', - 'Zeta': '\u0396', - 'zeta': '\u03B6', - 'zwj': '\u200D', - 'zwnj': '\u200C', -}; -// The &ngsp; pseudo-entity is denoting a space. see: -// https://github.com/dart-lang/angular/blob/0bb611387d29d65b5af7f9d2515ab571fd3fbee4/_tests/test/compiler/preserve_whitespace_test.dart -var NGSP_UNICODE = '\uE500'; -NAMED_ENTITIES['ngsp'] = NGSP_UNICODE; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var HtmlTagDefinition = /** @class */ (function () { - function HtmlTagDefinition(_a) { - var _this = this; - var _b = _a === void 0 ? {} : _a, closedByChildren = _b.closedByChildren, implicitNamespacePrefix = _b.implicitNamespacePrefix, _c = _b.contentType, contentType = _c === void 0 ? TagContentType.PARSABLE_DATA : _c, _d = _b.closedByParent, closedByParent = _d === void 0 ? false : _d, _e = _b.isVoid, isVoid = _e === void 0 ? false : _e, _f = _b.ignoreFirstLf, ignoreFirstLf = _f === void 0 ? false : _f; - this.closedByChildren = {}; - this.closedByParent = false; - this.canSelfClose = false; - if (closedByChildren && closedByChildren.length > 0) { - closedByChildren.forEach(function (tagName) { return _this.closedByChildren[tagName] = true; }); - } - this.isVoid = isVoid; - this.closedByParent = closedByParent || isVoid; - this.implicitNamespacePrefix = implicitNamespacePrefix || null; - this.contentType = contentType; - this.ignoreFirstLf = ignoreFirstLf; - } - HtmlTagDefinition.prototype.isClosedByChild = function (name) { - return this.isVoid || name.toLowerCase() in this.closedByChildren; - }; - return HtmlTagDefinition; -}()); -var _DEFAULT_TAG_DEFINITION; -// see http://www.w3.org/TR/html51/syntax.html#optional-tags -// This implementation does not fully conform to the HTML5 spec. -var TAG_DEFINITIONS; -function getHtmlTagDefinition(tagName) { - if (!TAG_DEFINITIONS) { - _DEFAULT_TAG_DEFINITION = new HtmlTagDefinition(); - TAG_DEFINITIONS = { - 'base': new HtmlTagDefinition({ isVoid: true }), - 'meta': new HtmlTagDefinition({ isVoid: true }), - 'area': new HtmlTagDefinition({ isVoid: true }), - 'embed': new HtmlTagDefinition({ isVoid: true }), - 'link': new HtmlTagDefinition({ isVoid: true }), - 'img': new HtmlTagDefinition({ isVoid: true }), - 'input': new HtmlTagDefinition({ isVoid: true }), - 'param': new HtmlTagDefinition({ isVoid: true }), - 'hr': new HtmlTagDefinition({ isVoid: true }), - 'br': new HtmlTagDefinition({ isVoid: true }), - 'source': new HtmlTagDefinition({ isVoid: true }), - 'track': new HtmlTagDefinition({ isVoid: true }), - 'wbr': new HtmlTagDefinition({ isVoid: true }), - 'p': new HtmlTagDefinition({ - closedByChildren: [ - 'address', 'article', 'aside', 'blockquote', 'div', 'dl', 'fieldset', - 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', - 'h6', 'header', 'hgroup', 'hr', 'main', 'nav', 'ol', - 'p', 'pre', 'section', 'table', 'ul' - ], - closedByParent: true - }), - 'thead': new HtmlTagDefinition({ closedByChildren: ['tbody', 'tfoot'] }), - 'tbody': new HtmlTagDefinition({ closedByChildren: ['tbody', 'tfoot'], closedByParent: true }), - 'tfoot': new HtmlTagDefinition({ closedByChildren: ['tbody'], closedByParent: true }), - 'tr': new HtmlTagDefinition({ closedByChildren: ['tr'], closedByParent: true }), - 'td': new HtmlTagDefinition({ closedByChildren: ['td', 'th'], closedByParent: true }), - 'th': new HtmlTagDefinition({ closedByChildren: ['td', 'th'], closedByParent: true }), - 'col': new HtmlTagDefinition({ isVoid: true }), - 'svg': new HtmlTagDefinition({ implicitNamespacePrefix: 'svg' }), - 'math': new HtmlTagDefinition({ implicitNamespacePrefix: 'math' }), - 'li': new HtmlTagDefinition({ closedByChildren: ['li'], closedByParent: true }), - 'dt': new HtmlTagDefinition({ closedByChildren: ['dt', 'dd'] }), - 'dd': new HtmlTagDefinition({ closedByChildren: ['dt', 'dd'], closedByParent: true }), - 'rb': new HtmlTagDefinition({ closedByChildren: ['rb', 'rt', 'rtc', 'rp'], closedByParent: true }), - 'rt': new HtmlTagDefinition({ closedByChildren: ['rb', 'rt', 'rtc', 'rp'], closedByParent: true }), - 'rtc': new HtmlTagDefinition({ closedByChildren: ['rb', 'rtc', 'rp'], closedByParent: true }), - 'rp': new HtmlTagDefinition({ closedByChildren: ['rb', 'rt', 'rtc', 'rp'], closedByParent: true }), - 'optgroup': new HtmlTagDefinition({ closedByChildren: ['optgroup'], closedByParent: true }), - 'option': new HtmlTagDefinition({ closedByChildren: ['option', 'optgroup'], closedByParent: true }), - 'pre': new HtmlTagDefinition({ ignoreFirstLf: true }), - 'listing': new HtmlTagDefinition({ ignoreFirstLf: true }), - 'style': new HtmlTagDefinition({ contentType: TagContentType.RAW_TEXT }), - 'script': new HtmlTagDefinition({ contentType: TagContentType.RAW_TEXT }), - 'title': new HtmlTagDefinition({ contentType: TagContentType.ESCAPABLE_RAW_TEXT }), - 'textarea': new HtmlTagDefinition({ contentType: TagContentType.ESCAPABLE_RAW_TEXT, ignoreFirstLf: true }), - }; - } - return TAG_DEFINITIONS[tagName.toLowerCase()] || _DEFAULT_TAG_DEFINITION; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _SELECTOR_REGEXP = new RegExp('(\\:not\\()|' + //":not(" - '([-\\w]+)|' + // "tag" - '(?:\\.([-\\w]+))|' + // ".class" - // "-" should appear first in the regexp below as FF31 parses "[.-\w]" as a range - '(?:\\[([-.\\w*]+)(?:=([\"\']?)([^\\]\"\']*)\\5)?\\])|' + // "[name]", "[name=value]", - // "[name="value"]", - // "[name='value']" - '(\\))|' + // ")" - '(\\s*,\\s*)', // "," -'g'); -/** - * A css selector contains an element name, - * css classes and attribute/value pairs with the purpose - * of selecting subsets out of them. - */ -var CssSelector = /** @class */ (function () { - function CssSelector() { - this.element = null; - this.classNames = []; - /** - * The selectors are encoded in pairs where: - * - even locations are attribute names - * - odd locations are attribute values. - * - * Example: - * Selector: `[key1=value1][key2]` would parse to: - * ``` - * ['key1', 'value1', 'key2', ''] - * ``` - */ - this.attrs = []; - this.notSelectors = []; - } - CssSelector.parse = function (selector) { - var results = []; - var _addResult = function (res, cssSel) { - if (cssSel.notSelectors.length > 0 && !cssSel.element && cssSel.classNames.length == 0 && - cssSel.attrs.length == 0) { - cssSel.element = '*'; - } - res.push(cssSel); - }; - var cssSelector = new CssSelector(); - var match; - var current = cssSelector; - var inNot = false; - _SELECTOR_REGEXP.lastIndex = 0; - while (match = _SELECTOR_REGEXP.exec(selector)) { - if (match[1]) { - if (inNot) { - throw new Error('Nesting :not is not allowed in a selector'); - } - inNot = true; - current = new CssSelector(); - cssSelector.notSelectors.push(current); - } - if (match[2]) { - current.setElement(match[2]); - } - if (match[3]) { - current.addClassName(match[3]); - } - if (match[4]) { - current.addAttribute(match[4], match[6]); - } - if (match[7]) { - inNot = false; - current = cssSelector; - } - if (match[8]) { - if (inNot) { - throw new Error('Multiple selectors in :not are not supported'); - } - _addResult(results, cssSelector); - cssSelector = current = new CssSelector(); - } - } - _addResult(results, cssSelector); - return results; - }; - CssSelector.prototype.isElementSelector = function () { - return this.hasElementSelector() && this.classNames.length == 0 && this.attrs.length == 0 && - this.notSelectors.length === 0; - }; - CssSelector.prototype.hasElementSelector = function () { return !!this.element; }; - CssSelector.prototype.setElement = function (element) { - if (element === void 0) { element = null; } - this.element = element; - }; - /** Gets a template string for an element that matches the selector. */ - CssSelector.prototype.getMatchingElementTemplate = function () { - var tagName = this.element || 'div'; - var classAttr = this.classNames.length > 0 ? " class=\"" + this.classNames.join(' ') + "\"" : ''; - var attrs = ''; - for (var i = 0; i < this.attrs.length; i += 2) { - var attrName = this.attrs[i]; - var attrValue = this.attrs[i + 1] !== '' ? "=\"" + this.attrs[i + 1] + "\"" : ''; - attrs += " " + attrName + attrValue; - } - return getHtmlTagDefinition(tagName).isVoid ? "<" + tagName + classAttr + attrs + "/>" : - "<" + tagName + classAttr + attrs + ">"; - }; - CssSelector.prototype.getAttrs = function () { - var result = []; - if (this.classNames.length > 0) { - result.push('class', this.classNames.join(' ')); - } - return result.concat(this.attrs); - }; - CssSelector.prototype.addAttribute = function (name, value) { - if (value === void 0) { value = ''; } - this.attrs.push(name, value && value.toLowerCase() || ''); - }; - CssSelector.prototype.addClassName = function (name) { this.classNames.push(name.toLowerCase()); }; - CssSelector.prototype.toString = function () { - var res = this.element || ''; - if (this.classNames) { - this.classNames.forEach(function (klass) { return res += "." + klass; }); - } - if (this.attrs) { - for (var i = 0; i < this.attrs.length; i += 2) { - var name_1 = this.attrs[i]; - var value = this.attrs[i + 1]; - res += "[" + name_1 + (value ? '=' + value : '') + "]"; - } - } - this.notSelectors.forEach(function (notSelector) { return res += ":not(" + notSelector + ")"; }); - return res; - }; - return CssSelector; -}()); -/** - * Reads a list of CssSelectors and allows to calculate which ones - * are contained in a given CssSelector. - */ -var SelectorMatcher = /** @class */ (function () { - function SelectorMatcher() { - this._elementMap = new Map(); - this._elementPartialMap = new Map(); - this._classMap = new Map(); - this._classPartialMap = new Map(); - this._attrValueMap = new Map(); - this._attrValuePartialMap = new Map(); - this._listContexts = []; - } - SelectorMatcher.createNotMatcher = function (notSelectors) { - var notMatcher = new SelectorMatcher(); - notMatcher.addSelectables(notSelectors, null); - return notMatcher; - }; - SelectorMatcher.prototype.addSelectables = function (cssSelectors, callbackCtxt) { - var listContext = null; - if (cssSelectors.length > 1) { - listContext = new SelectorListContext(cssSelectors); - this._listContexts.push(listContext); - } - for (var i = 0; i < cssSelectors.length; i++) { - this._addSelectable(cssSelectors[i], callbackCtxt, listContext); - } - }; - /** - * Add an object that can be found later on by calling `match`. - * @param cssSelector A css selector - * @param callbackCtxt An opaque object that will be given to the callback of the `match` function - */ - SelectorMatcher.prototype._addSelectable = function (cssSelector, callbackCtxt, listContext) { - var matcher = this; - var element = cssSelector.element; - var classNames = cssSelector.classNames; - var attrs = cssSelector.attrs; - var selectable = new SelectorContext(cssSelector, callbackCtxt, listContext); - if (element) { - var isTerminal = attrs.length === 0 && classNames.length === 0; - if (isTerminal) { - this._addTerminal(matcher._elementMap, element, selectable); - } - else { - matcher = this._addPartial(matcher._elementPartialMap, element); - } - } - if (classNames) { - for (var i = 0; i < classNames.length; i++) { - var isTerminal = attrs.length === 0 && i === classNames.length - 1; - var className = classNames[i]; - if (isTerminal) { - this._addTerminal(matcher._classMap, className, selectable); - } - else { - matcher = this._addPartial(matcher._classPartialMap, className); - } - } - } - if (attrs) { - for (var i = 0; i < attrs.length; i += 2) { - var isTerminal = i === attrs.length - 2; - var name_2 = attrs[i]; - var value = attrs[i + 1]; - if (isTerminal) { - var terminalMap = matcher._attrValueMap; - var terminalValuesMap = terminalMap.get(name_2); - if (!terminalValuesMap) { - terminalValuesMap = new Map(); - terminalMap.set(name_2, terminalValuesMap); - } - this._addTerminal(terminalValuesMap, value, selectable); - } - else { - var partialMap = matcher._attrValuePartialMap; - var partialValuesMap = partialMap.get(name_2); - if (!partialValuesMap) { - partialValuesMap = new Map(); - partialMap.set(name_2, partialValuesMap); - } - matcher = this._addPartial(partialValuesMap, value); - } - } - } - }; - SelectorMatcher.prototype._addTerminal = function (map, name, selectable) { - var terminalList = map.get(name); - if (!terminalList) { - terminalList = []; - map.set(name, terminalList); - } - terminalList.push(selectable); - }; - SelectorMatcher.prototype._addPartial = function (map, name) { - var matcher = map.get(name); - if (!matcher) { - matcher = new SelectorMatcher(); - map.set(name, matcher); - } - return matcher; - }; - /** - * Find the objects that have been added via `addSelectable` - * whose css selector is contained in the given css selector. - * @param cssSelector A css selector - * @param matchedCallback This callback will be called with the object handed into `addSelectable` - * @return boolean true if a match was found - */ - SelectorMatcher.prototype.match = function (cssSelector, matchedCallback) { - var result = false; - var element = cssSelector.element; - var classNames = cssSelector.classNames; - var attrs = cssSelector.attrs; - for (var i = 0; i < this._listContexts.length; i++) { - this._listContexts[i].alreadyMatched = false; - } - result = this._matchTerminal(this._elementMap, element, cssSelector, matchedCallback) || result; - result = this._matchPartial(this._elementPartialMap, element, cssSelector, matchedCallback) || - result; - if (classNames) { - for (var i = 0; i < classNames.length; i++) { - var className = classNames[i]; - result = - this._matchTerminal(this._classMap, className, cssSelector, matchedCallback) || result; - result = - this._matchPartial(this._classPartialMap, className, cssSelector, matchedCallback) || - result; - } - } - if (attrs) { - for (var i = 0; i < attrs.length; i += 2) { - var name_3 = attrs[i]; - var value = attrs[i + 1]; - var terminalValuesMap = this._attrValueMap.get(name_3); - if (value) { - result = - this._matchTerminal(terminalValuesMap, '', cssSelector, matchedCallback) || result; - } - result = - this._matchTerminal(terminalValuesMap, value, cssSelector, matchedCallback) || result; - var partialValuesMap = this._attrValuePartialMap.get(name_3); - if (value) { - result = this._matchPartial(partialValuesMap, '', cssSelector, matchedCallback) || result; - } - result = - this._matchPartial(partialValuesMap, value, cssSelector, matchedCallback) || result; - } - } - return result; - }; - /** @internal */ - SelectorMatcher.prototype._matchTerminal = function (map, name, cssSelector, matchedCallback) { - if (!map || typeof name !== 'string') { - return false; - } - var selectables = map.get(name) || []; - var starSelectables = map.get('*'); - if (starSelectables) { - selectables = selectables.concat(starSelectables); - } - if (selectables.length === 0) { - return false; - } - var selectable; - var result = false; - for (var i = 0; i < selectables.length; i++) { - selectable = selectables[i]; - result = selectable.finalize(cssSelector, matchedCallback) || result; - } - return result; - }; - /** @internal */ - SelectorMatcher.prototype._matchPartial = function (map, name, cssSelector, matchedCallback) { - if (!map || typeof name !== 'string') { - return false; - } - var nestedSelector = map.get(name); - if (!nestedSelector) { - return false; - } - // TODO(perf): get rid of recursion and measure again - // TODO(perf): don't pass the whole selector into the recursion, - // but only the not processed parts - return nestedSelector.match(cssSelector, matchedCallback); - }; - return SelectorMatcher; -}()); -var SelectorListContext = /** @class */ (function () { - function SelectorListContext(selectors) { - this.selectors = selectors; - this.alreadyMatched = false; - } - return SelectorListContext; -}()); -// Store context to pass back selector and context when a selector is matched -var SelectorContext = /** @class */ (function () { - function SelectorContext(selector, cbContext, listContext) { - this.selector = selector; - this.cbContext = cbContext; - this.listContext = listContext; - this.notSelectors = selector.notSelectors; - } - SelectorContext.prototype.finalize = function (cssSelector, callback) { - var result = true; - if (this.notSelectors.length > 0 && (!this.listContext || !this.listContext.alreadyMatched)) { - var notMatcher = SelectorMatcher.createNotMatcher(this.notSelectors); - result = !notMatcher.match(cssSelector, null); - } - if (result && callback && (!this.listContext || !this.listContext.alreadyMatched)) { - if (this.listContext) { - this.listContext.alreadyMatched = true; - } - callback(this.selector, this.cbContext); - } - return result; - }; - return SelectorContext; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var createInject = makeMetadataFactory('Inject', function (token) { return ({ token: token }); }); -var createInjectionToken = makeMetadataFactory('InjectionToken', function (desc) { return ({ _desc: desc, ngInjectableDef: undefined }); }); -var createAttribute = makeMetadataFactory('Attribute', function (attributeName) { return ({ attributeName: attributeName }); }); -var createContentChildren = makeMetadataFactory('ContentChildren', function (selector, data) { - if (data === void 0) { data = {}; } - return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ selector: selector, first: false, isViewQuery: false, descendants: false }, data)); -}); -var createContentChild = makeMetadataFactory('ContentChild', function (selector, data) { - if (data === void 0) { data = {}; } - return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ selector: selector, first: true, isViewQuery: false, descendants: true }, data)); -}); -var createViewChildren = makeMetadataFactory('ViewChildren', function (selector, data) { - if (data === void 0) { data = {}; } - return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ selector: selector, first: false, isViewQuery: true, descendants: true }, data)); -}); -var createViewChild = makeMetadataFactory('ViewChild', function (selector, data) { - return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ selector: selector, first: true, isViewQuery: true, descendants: true }, data)); -}); -var createDirective = makeMetadataFactory('Directive', function (dir) { - if (dir === void 0) { dir = {}; } - return dir; -}); -var ViewEncapsulation; -(function (ViewEncapsulation) { - ViewEncapsulation[ViewEncapsulation["Emulated"] = 0] = "Emulated"; - ViewEncapsulation[ViewEncapsulation["Native"] = 1] = "Native"; - ViewEncapsulation[ViewEncapsulation["None"] = 2] = "None"; - ViewEncapsulation[ViewEncapsulation["ShadowDom"] = 3] = "ShadowDom"; -})(ViewEncapsulation || (ViewEncapsulation = {})); -var ChangeDetectionStrategy; -(function (ChangeDetectionStrategy) { - ChangeDetectionStrategy[ChangeDetectionStrategy["OnPush"] = 0] = "OnPush"; - ChangeDetectionStrategy[ChangeDetectionStrategy["Default"] = 1] = "Default"; -})(ChangeDetectionStrategy || (ChangeDetectionStrategy = {})); -var createComponent = makeMetadataFactory('Component', function (c) { - if (c === void 0) { c = {}; } - return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ changeDetection: ChangeDetectionStrategy.Default }, c)); -}); -var createPipe = makeMetadataFactory('Pipe', function (p) { return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ pure: true }, p)); }); -var createInput = makeMetadataFactory('Input', function (bindingPropertyName) { return ({ bindingPropertyName: bindingPropertyName }); }); -var createOutput = makeMetadataFactory('Output', function (bindingPropertyName) { return ({ bindingPropertyName: bindingPropertyName }); }); -var createHostBinding = makeMetadataFactory('HostBinding', function (hostPropertyName) { return ({ hostPropertyName: hostPropertyName }); }); -var createHostListener = makeMetadataFactory('HostListener', function (eventName, args) { return ({ eventName: eventName, args: args }); }); -var createNgModule = makeMetadataFactory('NgModule', function (ngModule) { return ngModule; }); -var createInjectable = makeMetadataFactory('Injectable', function (injectable) { - if (injectable === void 0) { injectable = {}; } - return injectable; -}); -var CUSTOM_ELEMENTS_SCHEMA = { - name: 'custom-elements' -}; -var NO_ERRORS_SCHEMA = { - name: 'no-errors-schema' -}; -var createOptional = makeMetadataFactory('Optional'); -var createSelf = makeMetadataFactory('Self'); -var createSkipSelf = makeMetadataFactory('SkipSelf'); -var createHost = makeMetadataFactory('Host'); -var Type = Function; -var SecurityContext; -(function (SecurityContext) { - SecurityContext[SecurityContext["NONE"] = 0] = "NONE"; - SecurityContext[SecurityContext["HTML"] = 1] = "HTML"; - SecurityContext[SecurityContext["STYLE"] = 2] = "STYLE"; - SecurityContext[SecurityContext["SCRIPT"] = 3] = "SCRIPT"; - SecurityContext[SecurityContext["URL"] = 4] = "URL"; - SecurityContext[SecurityContext["RESOURCE_URL"] = 5] = "RESOURCE_URL"; -})(SecurityContext || (SecurityContext = {})); -var MissingTranslationStrategy; -(function (MissingTranslationStrategy) { - MissingTranslationStrategy[MissingTranslationStrategy["Error"] = 0] = "Error"; - MissingTranslationStrategy[MissingTranslationStrategy["Warning"] = 1] = "Warning"; - MissingTranslationStrategy[MissingTranslationStrategy["Ignore"] = 2] = "Ignore"; -})(MissingTranslationStrategy || (MissingTranslationStrategy = {})); -function makeMetadataFactory(name, props) { - // This must be declared as a function, not a fat arrow, so that ES2015 devmode produces code - // that works with the static_reflector.ts in the ViewEngine compiler. - // In particular, `_registerDecoratorOrConstructor` assumes that the value returned here can be - // new'ed. - function factory() { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(args)) : {}; - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({ ngMetadataName: name }, values); - } - factory.isTypeOf = function (obj) { return obj && obj.ngMetadataName === name; }; - factory.ngMetadataName = name; - return factory; -} -function parserSelectorToSimpleSelector(selector) { - var classes = selector.classNames && selector.classNames.length ? Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([8 /* CLASS */], selector.classNames) : - []; - var elementName = selector.element && selector.element !== '*' ? selector.element : ''; - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([elementName], selector.attrs, classes); -} -function parserSelectorToNegativeSelector(selector) { - var classes = selector.classNames && selector.classNames.length ? Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([8 /* CLASS */], selector.classNames) : - []; - if (selector.element) { - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([ - 1 /* NOT */ | 4 /* ELEMENT */, selector.element - ], selector.attrs, classes); - } - else if (selector.attrs.length) { - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([1 /* NOT */ | 2 /* ATTRIBUTE */], selector.attrs, classes); - } - else { - return selector.classNames && selector.classNames.length ? Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([1 /* NOT */ | 8 /* CLASS */], selector.classNames) : - []; - } -} -function parserSelectorToR3Selector(selector) { - var positive = parserSelectorToSimpleSelector(selector); - var negative = selector.notSelectors && selector.notSelectors.length ? - selector.notSelectors.map(function (notSelector) { return parserSelectorToNegativeSelector(notSelector); }) : - []; - return positive.concat.apply(positive, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(negative)); -} -function parseSelectorToR3Selector(selector) { - return selector ? CssSelector.parse(selector).map(parserSelectorToR3Selector) : []; -} - -var core = /*#__PURE__*/Object.freeze({ - createInject: createInject, - createInjectionToken: createInjectionToken, - createAttribute: createAttribute, - createContentChildren: createContentChildren, - createContentChild: createContentChild, - createViewChildren: createViewChildren, - createViewChild: createViewChild, - createDirective: createDirective, - get ViewEncapsulation () { return ViewEncapsulation; }, - get ChangeDetectionStrategy () { return ChangeDetectionStrategy; }, - createComponent: createComponent, - createPipe: createPipe, - createInput: createInput, - createOutput: createOutput, - createHostBinding: createHostBinding, - createHostListener: createHostListener, - createNgModule: createNgModule, - createInjectable: createInjectable, - CUSTOM_ELEMENTS_SCHEMA: CUSTOM_ELEMENTS_SCHEMA, - NO_ERRORS_SCHEMA: NO_ERRORS_SCHEMA, - createOptional: createOptional, - createSelf: createSelf, - createSkipSelf: createSkipSelf, - createHost: createHost, - Type: Type, - get SecurityContext () { return SecurityContext; }, - get MissingTranslationStrategy () { return MissingTranslationStrategy; }, - parseSelectorToR3Selector: parseSelectorToR3Selector -}); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -//// Types -var TypeModifier; -(function (TypeModifier) { - TypeModifier[TypeModifier["Const"] = 0] = "Const"; -})(TypeModifier || (TypeModifier = {})); -var Type$1 = /** @class */ (function () { - function Type(modifiers) { - if (modifiers === void 0) { modifiers = null; } - this.modifiers = modifiers; - if (!modifiers) { - this.modifiers = []; - } - } - Type.prototype.hasModifier = function (modifier) { return this.modifiers.indexOf(modifier) !== -1; }; - return Type; -}()); -var BuiltinTypeName; -(function (BuiltinTypeName) { - BuiltinTypeName[BuiltinTypeName["Dynamic"] = 0] = "Dynamic"; - BuiltinTypeName[BuiltinTypeName["Bool"] = 1] = "Bool"; - BuiltinTypeName[BuiltinTypeName["String"] = 2] = "String"; - BuiltinTypeName[BuiltinTypeName["Int"] = 3] = "Int"; - BuiltinTypeName[BuiltinTypeName["Number"] = 4] = "Number"; - BuiltinTypeName[BuiltinTypeName["Function"] = 5] = "Function"; - BuiltinTypeName[BuiltinTypeName["Inferred"] = 6] = "Inferred"; - BuiltinTypeName[BuiltinTypeName["None"] = 7] = "None"; -})(BuiltinTypeName || (BuiltinTypeName = {})); -var BuiltinType = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(BuiltinType, _super); - function BuiltinType(name, modifiers) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers) || this; - _this.name = name; - return _this; - } - BuiltinType.prototype.visitType = function (visitor, context) { - return visitor.visitBuiltinType(this, context); - }; - return BuiltinType; -}(Type$1)); -var ExpressionType = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ExpressionType, _super); - function ExpressionType(value, modifiers, typeParams) { - if (modifiers === void 0) { modifiers = null; } - if (typeParams === void 0) { typeParams = null; } - var _this = _super.call(this, modifiers) || this; - _this.value = value; - _this.typeParams = typeParams; - return _this; - } - ExpressionType.prototype.visitType = function (visitor, context) { - return visitor.visitExpressionType(this, context); - }; - return ExpressionType; -}(Type$1)); -var ArrayType = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ArrayType, _super); - function ArrayType(of, modifiers) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers) || this; - _this.of = of; - return _this; - } - ArrayType.prototype.visitType = function (visitor, context) { - return visitor.visitArrayType(this, context); - }; - return ArrayType; -}(Type$1)); -var MapType = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(MapType, _super); - function MapType(valueType, modifiers) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers) || this; - _this.valueType = valueType || null; - return _this; - } - MapType.prototype.visitType = function (visitor, context) { return visitor.visitMapType(this, context); }; - return MapType; -}(Type$1)); -var DYNAMIC_TYPE = new BuiltinType(BuiltinTypeName.Dynamic); -var INFERRED_TYPE = new BuiltinType(BuiltinTypeName.Inferred); -var BOOL_TYPE = new BuiltinType(BuiltinTypeName.Bool); -var INT_TYPE = new BuiltinType(BuiltinTypeName.Int); -var NUMBER_TYPE = new BuiltinType(BuiltinTypeName.Number); -var STRING_TYPE = new BuiltinType(BuiltinTypeName.String); -var FUNCTION_TYPE = new BuiltinType(BuiltinTypeName.Function); -var NONE_TYPE = new BuiltinType(BuiltinTypeName.None); -///// Expressions -var BinaryOperator; -(function (BinaryOperator) { - BinaryOperator[BinaryOperator["Equals"] = 0] = "Equals"; - BinaryOperator[BinaryOperator["NotEquals"] = 1] = "NotEquals"; - BinaryOperator[BinaryOperator["Identical"] = 2] = "Identical"; - BinaryOperator[BinaryOperator["NotIdentical"] = 3] = "NotIdentical"; - BinaryOperator[BinaryOperator["Minus"] = 4] = "Minus"; - BinaryOperator[BinaryOperator["Plus"] = 5] = "Plus"; - BinaryOperator[BinaryOperator["Divide"] = 6] = "Divide"; - BinaryOperator[BinaryOperator["Multiply"] = 7] = "Multiply"; - BinaryOperator[BinaryOperator["Modulo"] = 8] = "Modulo"; - BinaryOperator[BinaryOperator["And"] = 9] = "And"; - BinaryOperator[BinaryOperator["Or"] = 10] = "Or"; - BinaryOperator[BinaryOperator["BitwiseAnd"] = 11] = "BitwiseAnd"; - BinaryOperator[BinaryOperator["Lower"] = 12] = "Lower"; - BinaryOperator[BinaryOperator["LowerEquals"] = 13] = "LowerEquals"; - BinaryOperator[BinaryOperator["Bigger"] = 14] = "Bigger"; - BinaryOperator[BinaryOperator["BiggerEquals"] = 15] = "BiggerEquals"; -})(BinaryOperator || (BinaryOperator = {})); -function nullSafeIsEquivalent(base, other) { - if (base == null || other == null) { - return base == other; - } - return base.isEquivalent(other); -} -function areAllEquivalent(base, other) { - var len = base.length; - if (len !== other.length) { - return false; - } - for (var i = 0; i < len; i++) { - if (!base[i].isEquivalent(other[i])) { - return false; - } - } - return true; -} -var Expression = /** @class */ (function () { - function Expression(type, sourceSpan) { - this.type = type || null; - this.sourceSpan = sourceSpan || null; - } - Expression.prototype.prop = function (name, sourceSpan) { - return new ReadPropExpr(this, name, null, sourceSpan); - }; - Expression.prototype.key = function (index, type, sourceSpan) { - return new ReadKeyExpr(this, index, type, sourceSpan); - }; - Expression.prototype.callMethod = function (name, params, sourceSpan) { - return new InvokeMethodExpr(this, name, params, null, sourceSpan); - }; - Expression.prototype.callFn = function (params, sourceSpan) { - return new InvokeFunctionExpr(this, params, null, sourceSpan); - }; - Expression.prototype.instantiate = function (params, type, sourceSpan) { - return new InstantiateExpr(this, params, type, sourceSpan); - }; - Expression.prototype.conditional = function (trueCase, falseCase, sourceSpan) { - if (falseCase === void 0) { falseCase = null; } - return new ConditionalExpr(this, trueCase, falseCase, null, sourceSpan); - }; - Expression.prototype.equals = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Equals, this, rhs, null, sourceSpan); - }; - Expression.prototype.notEquals = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.NotEquals, this, rhs, null, sourceSpan); - }; - Expression.prototype.identical = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Identical, this, rhs, null, sourceSpan); - }; - Expression.prototype.notIdentical = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.NotIdentical, this, rhs, null, sourceSpan); - }; - Expression.prototype.minus = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Minus, this, rhs, null, sourceSpan); - }; - Expression.prototype.plus = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Plus, this, rhs, null, sourceSpan); - }; - Expression.prototype.divide = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Divide, this, rhs, null, sourceSpan); - }; - Expression.prototype.multiply = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Multiply, this, rhs, null, sourceSpan); - }; - Expression.prototype.modulo = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Modulo, this, rhs, null, sourceSpan); - }; - Expression.prototype.and = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.And, this, rhs, null, sourceSpan); - }; - Expression.prototype.bitwiseAnd = function (rhs, sourceSpan, parens) { - if (parens === void 0) { parens = true; } - return new BinaryOperatorExpr(BinaryOperator.BitwiseAnd, this, rhs, null, sourceSpan, parens); - }; - Expression.prototype.or = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Or, this, rhs, null, sourceSpan); - }; - Expression.prototype.lower = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Lower, this, rhs, null, sourceSpan); - }; - Expression.prototype.lowerEquals = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.LowerEquals, this, rhs, null, sourceSpan); - }; - Expression.prototype.bigger = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.Bigger, this, rhs, null, sourceSpan); - }; - Expression.prototype.biggerEquals = function (rhs, sourceSpan) { - return new BinaryOperatorExpr(BinaryOperator.BiggerEquals, this, rhs, null, sourceSpan); - }; - Expression.prototype.isBlank = function (sourceSpan) { - // Note: We use equals by purpose here to compare to null and undefined in JS. - // We use the typed null to allow strictNullChecks to narrow types. - return this.equals(TYPED_NULL_EXPR, sourceSpan); - }; - Expression.prototype.cast = function (type, sourceSpan) { - return new CastExpr(this, type, sourceSpan); - }; - Expression.prototype.toStmt = function () { return new ExpressionStatement(this, null); }; - return Expression; -}()); -var BuiltinVar; -(function (BuiltinVar) { - BuiltinVar[BuiltinVar["This"] = 0] = "This"; - BuiltinVar[BuiltinVar["Super"] = 1] = "Super"; - BuiltinVar[BuiltinVar["CatchError"] = 2] = "CatchError"; - BuiltinVar[BuiltinVar["CatchStack"] = 3] = "CatchStack"; -})(BuiltinVar || (BuiltinVar = {})); -var ReadVarExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ReadVarExpr, _super); - function ReadVarExpr(name, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - if (typeof name === 'string') { - _this.name = name; - _this.builtin = null; - } - else { - _this.name = null; - _this.builtin = name; - } - return _this; - } - ReadVarExpr.prototype.isEquivalent = function (e) { - return e instanceof ReadVarExpr && this.name === e.name && this.builtin === e.builtin; - }; - ReadVarExpr.prototype.isConstant = function () { return false; }; - ReadVarExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitReadVarExpr(this, context); - }; - ReadVarExpr.prototype.set = function (value) { - if (!this.name) { - throw new Error("Built in variable " + this.builtin + " can not be assigned to."); - } - return new WriteVarExpr(this.name, value, null, this.sourceSpan); - }; - return ReadVarExpr; -}(Expression)); -var TypeofExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(TypeofExpr, _super); - function TypeofExpr(expr, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.expr = expr; - return _this; - } - TypeofExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitTypeofExpr(this, context); - }; - TypeofExpr.prototype.isEquivalent = function (e) { - return e instanceof TypeofExpr && e.expr.isEquivalent(this.expr); - }; - TypeofExpr.prototype.isConstant = function () { return this.expr.isConstant(); }; - return TypeofExpr; -}(Expression)); -var WrappedNodeExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(WrappedNodeExpr, _super); - function WrappedNodeExpr(node, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.node = node; - return _this; - } - WrappedNodeExpr.prototype.isEquivalent = function (e) { - return e instanceof WrappedNodeExpr && this.node === e.node; - }; - WrappedNodeExpr.prototype.isConstant = function () { return false; }; - WrappedNodeExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitWrappedNodeExpr(this, context); - }; - return WrappedNodeExpr; -}(Expression)); -var WriteVarExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(WriteVarExpr, _super); - function WriteVarExpr(name, value, type, sourceSpan) { - var _this = _super.call(this, type || value.type, sourceSpan) || this; - _this.name = name; - _this.value = value; - return _this; - } - WriteVarExpr.prototype.isEquivalent = function (e) { - return e instanceof WriteVarExpr && this.name === e.name && this.value.isEquivalent(e.value); - }; - WriteVarExpr.prototype.isConstant = function () { return false; }; - WriteVarExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitWriteVarExpr(this, context); - }; - WriteVarExpr.prototype.toDeclStmt = function (type, modifiers) { - return new DeclareVarStmt(this.name, this.value, type, modifiers, this.sourceSpan); - }; - WriteVarExpr.prototype.toConstDecl = function () { return this.toDeclStmt(INFERRED_TYPE, [StmtModifier.Final]); }; - return WriteVarExpr; -}(Expression)); -var WriteKeyExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(WriteKeyExpr, _super); - function WriteKeyExpr(receiver, index, value, type, sourceSpan) { - var _this = _super.call(this, type || value.type, sourceSpan) || this; - _this.receiver = receiver; - _this.index = index; - _this.value = value; - return _this; - } - WriteKeyExpr.prototype.isEquivalent = function (e) { - return e instanceof WriteKeyExpr && this.receiver.isEquivalent(e.receiver) && - this.index.isEquivalent(e.index) && this.value.isEquivalent(e.value); - }; - WriteKeyExpr.prototype.isConstant = function () { return false; }; - WriteKeyExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitWriteKeyExpr(this, context); - }; - return WriteKeyExpr; -}(Expression)); -var WritePropExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(WritePropExpr, _super); - function WritePropExpr(receiver, name, value, type, sourceSpan) { - var _this = _super.call(this, type || value.type, sourceSpan) || this; - _this.receiver = receiver; - _this.name = name; - _this.value = value; - return _this; - } - WritePropExpr.prototype.isEquivalent = function (e) { - return e instanceof WritePropExpr && this.receiver.isEquivalent(e.receiver) && - this.name === e.name && this.value.isEquivalent(e.value); - }; - WritePropExpr.prototype.isConstant = function () { return false; }; - WritePropExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitWritePropExpr(this, context); - }; - return WritePropExpr; -}(Expression)); -var BuiltinMethod; -(function (BuiltinMethod) { - BuiltinMethod[BuiltinMethod["ConcatArray"] = 0] = "ConcatArray"; - BuiltinMethod[BuiltinMethod["SubscribeObservable"] = 1] = "SubscribeObservable"; - BuiltinMethod[BuiltinMethod["Bind"] = 2] = "Bind"; -})(BuiltinMethod || (BuiltinMethod = {})); -var InvokeMethodExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(InvokeMethodExpr, _super); - function InvokeMethodExpr(receiver, method, args, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.receiver = receiver; - _this.args = args; - if (typeof method === 'string') { - _this.name = method; - _this.builtin = null; - } - else { - _this.name = null; - _this.builtin = method; - } - return _this; - } - InvokeMethodExpr.prototype.isEquivalent = function (e) { - return e instanceof InvokeMethodExpr && this.receiver.isEquivalent(e.receiver) && - this.name === e.name && this.builtin === e.builtin && areAllEquivalent(this.args, e.args); - }; - InvokeMethodExpr.prototype.isConstant = function () { return false; }; - InvokeMethodExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitInvokeMethodExpr(this, context); - }; - return InvokeMethodExpr; -}(Expression)); -var InvokeFunctionExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(InvokeFunctionExpr, _super); - function InvokeFunctionExpr(fn, args, type, sourceSpan, pure) { - if (pure === void 0) { pure = false; } - var _this = _super.call(this, type, sourceSpan) || this; - _this.fn = fn; - _this.args = args; - _this.pure = pure; - return _this; - } - InvokeFunctionExpr.prototype.isEquivalent = function (e) { - return e instanceof InvokeFunctionExpr && this.fn.isEquivalent(e.fn) && - areAllEquivalent(this.args, e.args) && this.pure === e.pure; - }; - InvokeFunctionExpr.prototype.isConstant = function () { return false; }; - InvokeFunctionExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitInvokeFunctionExpr(this, context); - }; - return InvokeFunctionExpr; -}(Expression)); -var InstantiateExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(InstantiateExpr, _super); - function InstantiateExpr(classExpr, args, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.classExpr = classExpr; - _this.args = args; - return _this; - } - InstantiateExpr.prototype.isEquivalent = function (e) { - return e instanceof InstantiateExpr && this.classExpr.isEquivalent(e.classExpr) && - areAllEquivalent(this.args, e.args); - }; - InstantiateExpr.prototype.isConstant = function () { return false; }; - InstantiateExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitInstantiateExpr(this, context); - }; - return InstantiateExpr; -}(Expression)); -var LiteralExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralExpr, _super); - function LiteralExpr(value, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.value = value; - return _this; - } - LiteralExpr.prototype.isEquivalent = function (e) { - return e instanceof LiteralExpr && this.value === e.value; - }; - LiteralExpr.prototype.isConstant = function () { return true; }; - LiteralExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitLiteralExpr(this, context); - }; - return LiteralExpr; -}(Expression)); -var ExternalExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ExternalExpr, _super); - function ExternalExpr(value, type, typeParams, sourceSpan) { - if (typeParams === void 0) { typeParams = null; } - var _this = _super.call(this, type, sourceSpan) || this; - _this.value = value; - _this.typeParams = typeParams; - return _this; - } - ExternalExpr.prototype.isEquivalent = function (e) { - return e instanceof ExternalExpr && this.value.name === e.value.name && - this.value.moduleName === e.value.moduleName && this.value.runtime === e.value.runtime; - }; - ExternalExpr.prototype.isConstant = function () { return false; }; - ExternalExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitExternalExpr(this, context); - }; - return ExternalExpr; -}(Expression)); -var ExternalReference = /** @class */ (function () { - function ExternalReference(moduleName, name, runtime) { - this.moduleName = moduleName; - this.name = name; - this.runtime = runtime; - } - return ExternalReference; -}()); -var ConditionalExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ConditionalExpr, _super); - function ConditionalExpr(condition, trueCase, falseCase, type, sourceSpan) { - if (falseCase === void 0) { falseCase = null; } - var _this = _super.call(this, type || trueCase.type, sourceSpan) || this; - _this.condition = condition; - _this.falseCase = falseCase; - _this.trueCase = trueCase; - return _this; - } - ConditionalExpr.prototype.isEquivalent = function (e) { - return e instanceof ConditionalExpr && this.condition.isEquivalent(e.condition) && - this.trueCase.isEquivalent(e.trueCase) && nullSafeIsEquivalent(this.falseCase, e.falseCase); - }; - ConditionalExpr.prototype.isConstant = function () { return false; }; - ConditionalExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitConditionalExpr(this, context); - }; - return ConditionalExpr; -}(Expression)); -var NotExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(NotExpr, _super); - function NotExpr(condition, sourceSpan) { - var _this = _super.call(this, BOOL_TYPE, sourceSpan) || this; - _this.condition = condition; - return _this; - } - NotExpr.prototype.isEquivalent = function (e) { - return e instanceof NotExpr && this.condition.isEquivalent(e.condition); - }; - NotExpr.prototype.isConstant = function () { return false; }; - NotExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitNotExpr(this, context); - }; - return NotExpr; -}(Expression)); -var AssertNotNull = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(AssertNotNull, _super); - function AssertNotNull(condition, sourceSpan) { - var _this = _super.call(this, condition.type, sourceSpan) || this; - _this.condition = condition; - return _this; - } - AssertNotNull.prototype.isEquivalent = function (e) { - return e instanceof AssertNotNull && this.condition.isEquivalent(e.condition); - }; - AssertNotNull.prototype.isConstant = function () { return false; }; - AssertNotNull.prototype.visitExpression = function (visitor, context) { - return visitor.visitAssertNotNullExpr(this, context); - }; - return AssertNotNull; -}(Expression)); -var CastExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(CastExpr, _super); - function CastExpr(value, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.value = value; - return _this; - } - CastExpr.prototype.isEquivalent = function (e) { - return e instanceof CastExpr && this.value.isEquivalent(e.value); - }; - CastExpr.prototype.isConstant = function () { return false; }; - CastExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitCastExpr(this, context); - }; - return CastExpr; -}(Expression)); -var FnParam = /** @class */ (function () { - function FnParam(name, type) { - if (type === void 0) { type = null; } - this.name = name; - this.type = type; - } - FnParam.prototype.isEquivalent = function (param) { return this.name === param.name; }; - return FnParam; -}()); -var FunctionExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(FunctionExpr, _super); - function FunctionExpr(params, statements, type, sourceSpan, name) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.params = params; - _this.statements = statements; - _this.name = name; - return _this; - } - FunctionExpr.prototype.isEquivalent = function (e) { - return e instanceof FunctionExpr && areAllEquivalent(this.params, e.params) && - areAllEquivalent(this.statements, e.statements); - }; - FunctionExpr.prototype.isConstant = function () { return false; }; - FunctionExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitFunctionExpr(this, context); - }; - FunctionExpr.prototype.toDeclStmt = function (name, modifiers) { - if (modifiers === void 0) { modifiers = null; } - return new DeclareFunctionStmt(name, this.params, this.statements, this.type, modifiers, this.sourceSpan); - }; - return FunctionExpr; -}(Expression)); -var BinaryOperatorExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(BinaryOperatorExpr, _super); - function BinaryOperatorExpr(operator, lhs, rhs, type, sourceSpan, parens) { - if (parens === void 0) { parens = true; } - var _this = _super.call(this, type || lhs.type, sourceSpan) || this; - _this.operator = operator; - _this.rhs = rhs; - _this.parens = parens; - _this.lhs = lhs; - return _this; - } - BinaryOperatorExpr.prototype.isEquivalent = function (e) { - return e instanceof BinaryOperatorExpr && this.operator === e.operator && - this.lhs.isEquivalent(e.lhs) && this.rhs.isEquivalent(e.rhs); - }; - BinaryOperatorExpr.prototype.isConstant = function () { return false; }; - BinaryOperatorExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitBinaryOperatorExpr(this, context); - }; - return BinaryOperatorExpr; -}(Expression)); -var ReadPropExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ReadPropExpr, _super); - function ReadPropExpr(receiver, name, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.receiver = receiver; - _this.name = name; - return _this; - } - ReadPropExpr.prototype.isEquivalent = function (e) { - return e instanceof ReadPropExpr && this.receiver.isEquivalent(e.receiver) && - this.name === e.name; - }; - ReadPropExpr.prototype.isConstant = function () { return false; }; - ReadPropExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitReadPropExpr(this, context); - }; - ReadPropExpr.prototype.set = function (value) { - return new WritePropExpr(this.receiver, this.name, value, null, this.sourceSpan); - }; - return ReadPropExpr; -}(Expression)); -var ReadKeyExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ReadKeyExpr, _super); - function ReadKeyExpr(receiver, index, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.receiver = receiver; - _this.index = index; - return _this; - } - ReadKeyExpr.prototype.isEquivalent = function (e) { - return e instanceof ReadKeyExpr && this.receiver.isEquivalent(e.receiver) && - this.index.isEquivalent(e.index); - }; - ReadKeyExpr.prototype.isConstant = function () { return false; }; - ReadKeyExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitReadKeyExpr(this, context); - }; - ReadKeyExpr.prototype.set = function (value) { - return new WriteKeyExpr(this.receiver, this.index, value, null, this.sourceSpan); - }; - return ReadKeyExpr; -}(Expression)); -var LiteralArrayExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralArrayExpr, _super); - function LiteralArrayExpr(entries, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.entries = entries; - return _this; - } - LiteralArrayExpr.prototype.isConstant = function () { return this.entries.every(function (e) { return e.isConstant(); }); }; - LiteralArrayExpr.prototype.isEquivalent = function (e) { - return e instanceof LiteralArrayExpr && areAllEquivalent(this.entries, e.entries); - }; - LiteralArrayExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitLiteralArrayExpr(this, context); - }; - return LiteralArrayExpr; -}(Expression)); -var LiteralMapEntry = /** @class */ (function () { - function LiteralMapEntry(key, value, quoted) { - this.key = key; - this.value = value; - this.quoted = quoted; - } - LiteralMapEntry.prototype.isEquivalent = function (e) { - return this.key === e.key && this.value.isEquivalent(e.value); - }; - return LiteralMapEntry; -}()); -var LiteralMapExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralMapExpr, _super); - function LiteralMapExpr(entries, type, sourceSpan) { - var _this = _super.call(this, type, sourceSpan) || this; - _this.entries = entries; - _this.valueType = null; - if (type) { - _this.valueType = type.valueType; - } - return _this; - } - LiteralMapExpr.prototype.isEquivalent = function (e) { - return e instanceof LiteralMapExpr && areAllEquivalent(this.entries, e.entries); - }; - LiteralMapExpr.prototype.isConstant = function () { return this.entries.every(function (e) { return e.value.isConstant(); }); }; - LiteralMapExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitLiteralMapExpr(this, context); - }; - return LiteralMapExpr; -}(Expression)); -var CommaExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(CommaExpr, _super); - function CommaExpr(parts, sourceSpan) { - var _this = _super.call(this, parts[parts.length - 1].type, sourceSpan) || this; - _this.parts = parts; - return _this; - } - CommaExpr.prototype.isEquivalent = function (e) { - return e instanceof CommaExpr && areAllEquivalent(this.parts, e.parts); - }; - CommaExpr.prototype.isConstant = function () { return false; }; - CommaExpr.prototype.visitExpression = function (visitor, context) { - return visitor.visitCommaExpr(this, context); - }; - return CommaExpr; -}(Expression)); -var THIS_EXPR = new ReadVarExpr(BuiltinVar.This, null, null); -var SUPER_EXPR = new ReadVarExpr(BuiltinVar.Super, null, null); -var CATCH_ERROR_VAR = new ReadVarExpr(BuiltinVar.CatchError, null, null); -var CATCH_STACK_VAR = new ReadVarExpr(BuiltinVar.CatchStack, null, null); -var NULL_EXPR = new LiteralExpr(null, null, null); -var TYPED_NULL_EXPR = new LiteralExpr(null, INFERRED_TYPE, null); -//// Statements -var StmtModifier; -(function (StmtModifier) { - StmtModifier[StmtModifier["Final"] = 0] = "Final"; - StmtModifier[StmtModifier["Private"] = 1] = "Private"; - StmtModifier[StmtModifier["Exported"] = 2] = "Exported"; - StmtModifier[StmtModifier["Static"] = 3] = "Static"; -})(StmtModifier || (StmtModifier = {})); -var Statement = /** @class */ (function () { - function Statement(modifiers, sourceSpan) { - this.modifiers = modifiers || []; - this.sourceSpan = sourceSpan || null; - } - Statement.prototype.hasModifier = function (modifier) { return this.modifiers.indexOf(modifier) !== -1; }; - return Statement; -}()); -var DeclareVarStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(DeclareVarStmt, _super); - function DeclareVarStmt(name, value, type, modifiers, sourceSpan) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers, sourceSpan) || this; - _this.name = name; - _this.value = value; - _this.type = type || (value && value.type) || null; - return _this; - } - DeclareVarStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof DeclareVarStmt && this.name === stmt.name && - (this.value ? !!stmt.value && this.value.isEquivalent(stmt.value) : !stmt.value); - }; - DeclareVarStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitDeclareVarStmt(this, context); - }; - return DeclareVarStmt; -}(Statement)); -var DeclareFunctionStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(DeclareFunctionStmt, _super); - function DeclareFunctionStmt(name, params, statements, type, modifiers, sourceSpan) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers, sourceSpan) || this; - _this.name = name; - _this.params = params; - _this.statements = statements; - _this.type = type || null; - return _this; - } - DeclareFunctionStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof DeclareFunctionStmt && areAllEquivalent(this.params, stmt.params) && - areAllEquivalent(this.statements, stmt.statements); - }; - DeclareFunctionStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitDeclareFunctionStmt(this, context); - }; - return DeclareFunctionStmt; -}(Statement)); -var ExpressionStatement = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ExpressionStatement, _super); - function ExpressionStatement(expr, sourceSpan) { - var _this = _super.call(this, null, sourceSpan) || this; - _this.expr = expr; - return _this; - } - ExpressionStatement.prototype.isEquivalent = function (stmt) { - return stmt instanceof ExpressionStatement && this.expr.isEquivalent(stmt.expr); - }; - ExpressionStatement.prototype.visitStatement = function (visitor, context) { - return visitor.visitExpressionStmt(this, context); - }; - return ExpressionStatement; -}(Statement)); -var ReturnStatement = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ReturnStatement, _super); - function ReturnStatement(value, sourceSpan) { - var _this = _super.call(this, null, sourceSpan) || this; - _this.value = value; - return _this; - } - ReturnStatement.prototype.isEquivalent = function (stmt) { - return stmt instanceof ReturnStatement && this.value.isEquivalent(stmt.value); - }; - ReturnStatement.prototype.visitStatement = function (visitor, context) { - return visitor.visitReturnStmt(this, context); - }; - return ReturnStatement; -}(Statement)); -var AbstractClassPart = /** @class */ (function () { - function AbstractClassPart(type, modifiers) { - this.modifiers = modifiers; - if (!modifiers) { - this.modifiers = []; - } - this.type = type || null; - } - AbstractClassPart.prototype.hasModifier = function (modifier) { return this.modifiers.indexOf(modifier) !== -1; }; - return AbstractClassPart; -}()); -var ClassField = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ClassField, _super); - function ClassField(name, type, modifiers, initializer) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, type, modifiers) || this; - _this.name = name; - _this.initializer = initializer; - return _this; - } - ClassField.prototype.isEquivalent = function (f) { return this.name === f.name; }; - return ClassField; -}(AbstractClassPart)); -var ClassMethod = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ClassMethod, _super); - function ClassMethod(name, params, body, type, modifiers) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, type, modifiers) || this; - _this.name = name; - _this.params = params; - _this.body = body; - return _this; - } - ClassMethod.prototype.isEquivalent = function (m) { - return this.name === m.name && areAllEquivalent(this.body, m.body); - }; - return ClassMethod; -}(AbstractClassPart)); -var ClassGetter = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ClassGetter, _super); - function ClassGetter(name, body, type, modifiers) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, type, modifiers) || this; - _this.name = name; - _this.body = body; - return _this; - } - ClassGetter.prototype.isEquivalent = function (m) { - return this.name === m.name && areAllEquivalent(this.body, m.body); - }; - return ClassGetter; -}(AbstractClassPart)); -var ClassStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ClassStmt, _super); - function ClassStmt(name, parent, fields, getters, constructorMethod, methods, modifiers, sourceSpan) { - if (modifiers === void 0) { modifiers = null; } - var _this = _super.call(this, modifiers, sourceSpan) || this; - _this.name = name; - _this.parent = parent; - _this.fields = fields; - _this.getters = getters; - _this.constructorMethod = constructorMethod; - _this.methods = methods; - return _this; - } - ClassStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof ClassStmt && this.name === stmt.name && - nullSafeIsEquivalent(this.parent, stmt.parent) && - areAllEquivalent(this.fields, stmt.fields) && - areAllEquivalent(this.getters, stmt.getters) && - this.constructorMethod.isEquivalent(stmt.constructorMethod) && - areAllEquivalent(this.methods, stmt.methods); - }; - ClassStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitDeclareClassStmt(this, context); - }; - return ClassStmt; -}(Statement)); -var IfStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(IfStmt, _super); - function IfStmt(condition, trueCase, falseCase, sourceSpan) { - if (falseCase === void 0) { falseCase = []; } - var _this = _super.call(this, null, sourceSpan) || this; - _this.condition = condition; - _this.trueCase = trueCase; - _this.falseCase = falseCase; - return _this; - } - IfStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof IfStmt && this.condition.isEquivalent(stmt.condition) && - areAllEquivalent(this.trueCase, stmt.trueCase) && - areAllEquivalent(this.falseCase, stmt.falseCase); - }; - IfStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitIfStmt(this, context); - }; - return IfStmt; -}(Statement)); -var CommentStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(CommentStmt, _super); - function CommentStmt(comment, multiline, sourceSpan) { - if (multiline === void 0) { multiline = false; } - var _this = _super.call(this, null, sourceSpan) || this; - _this.comment = comment; - _this.multiline = multiline; - return _this; - } - CommentStmt.prototype.isEquivalent = function (stmt) { return stmt instanceof CommentStmt; }; - CommentStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitCommentStmt(this, context); - }; - return CommentStmt; -}(Statement)); -var JSDocCommentStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(JSDocCommentStmt, _super); - function JSDocCommentStmt(tags, sourceSpan) { - if (tags === void 0) { tags = []; } - var _this = _super.call(this, null, sourceSpan) || this; - _this.tags = tags; - return _this; - } - JSDocCommentStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof JSDocCommentStmt && this.toString() === stmt.toString(); - }; - JSDocCommentStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitJSDocCommentStmt(this, context); - }; - JSDocCommentStmt.prototype.toString = function () { return serializeTags(this.tags); }; - return JSDocCommentStmt; -}(Statement)); -var TryCatchStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(TryCatchStmt, _super); - function TryCatchStmt(bodyStmts, catchStmts, sourceSpan) { - var _this = _super.call(this, null, sourceSpan) || this; - _this.bodyStmts = bodyStmts; - _this.catchStmts = catchStmts; - return _this; - } - TryCatchStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof TryCatchStmt && areAllEquivalent(this.bodyStmts, stmt.bodyStmts) && - areAllEquivalent(this.catchStmts, stmt.catchStmts); - }; - TryCatchStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitTryCatchStmt(this, context); - }; - return TryCatchStmt; -}(Statement)); -var ThrowStmt = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ThrowStmt, _super); - function ThrowStmt(error, sourceSpan) { - var _this = _super.call(this, null, sourceSpan) || this; - _this.error = error; - return _this; - } - ThrowStmt.prototype.isEquivalent = function (stmt) { - return stmt instanceof TryCatchStmt && this.error.isEquivalent(stmt.error); - }; - ThrowStmt.prototype.visitStatement = function (visitor, context) { - return visitor.visitThrowStmt(this, context); - }; - return ThrowStmt; -}(Statement)); -var AstTransformer = /** @class */ (function () { - function AstTransformer() { - } - AstTransformer.prototype.transformExpr = function (expr, context) { return expr; }; - AstTransformer.prototype.transformStmt = function (stmt, context) { return stmt; }; - AstTransformer.prototype.visitReadVarExpr = function (ast, context) { return this.transformExpr(ast, context); }; - AstTransformer.prototype.visitWrappedNodeExpr = function (ast, context) { - return this.transformExpr(ast, context); - }; - AstTransformer.prototype.visitTypeofExpr = function (expr, context) { - return this.transformExpr(new TypeofExpr(expr.expr.visitExpression(this, context), expr.type, expr.sourceSpan), context); - }; - AstTransformer.prototype.visitWriteVarExpr = function (expr, context) { - return this.transformExpr(new WriteVarExpr(expr.name, expr.value.visitExpression(this, context), expr.type, expr.sourceSpan), context); - }; - AstTransformer.prototype.visitWriteKeyExpr = function (expr, context) { - return this.transformExpr(new WriteKeyExpr(expr.receiver.visitExpression(this, context), expr.index.visitExpression(this, context), expr.value.visitExpression(this, context), expr.type, expr.sourceSpan), context); - }; - AstTransformer.prototype.visitWritePropExpr = function (expr, context) { - return this.transformExpr(new WritePropExpr(expr.receiver.visitExpression(this, context), expr.name, expr.value.visitExpression(this, context), expr.type, expr.sourceSpan), context); - }; - AstTransformer.prototype.visitInvokeMethodExpr = function (ast, context) { - var method = ast.builtin || ast.name; - return this.transformExpr(new InvokeMethodExpr(ast.receiver.visitExpression(this, context), method, this.visitAllExpressions(ast.args, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitInvokeFunctionExpr = function (ast, context) { - return this.transformExpr(new InvokeFunctionExpr(ast.fn.visitExpression(this, context), this.visitAllExpressions(ast.args, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitInstantiateExpr = function (ast, context) { - return this.transformExpr(new InstantiateExpr(ast.classExpr.visitExpression(this, context), this.visitAllExpressions(ast.args, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitLiteralExpr = function (ast, context) { return this.transformExpr(ast, context); }; - AstTransformer.prototype.visitExternalExpr = function (ast, context) { - return this.transformExpr(ast, context); - }; - AstTransformer.prototype.visitConditionalExpr = function (ast, context) { - return this.transformExpr(new ConditionalExpr(ast.condition.visitExpression(this, context), ast.trueCase.visitExpression(this, context), ast.falseCase.visitExpression(this, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitNotExpr = function (ast, context) { - return this.transformExpr(new NotExpr(ast.condition.visitExpression(this, context), ast.sourceSpan), context); - }; - AstTransformer.prototype.visitAssertNotNullExpr = function (ast, context) { - return this.transformExpr(new AssertNotNull(ast.condition.visitExpression(this, context), ast.sourceSpan), context); - }; - AstTransformer.prototype.visitCastExpr = function (ast, context) { - return this.transformExpr(new CastExpr(ast.value.visitExpression(this, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitFunctionExpr = function (ast, context) { - return this.transformExpr(new FunctionExpr(ast.params, this.visitAllStatements(ast.statements, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitBinaryOperatorExpr = function (ast, context) { - return this.transformExpr(new BinaryOperatorExpr(ast.operator, ast.lhs.visitExpression(this, context), ast.rhs.visitExpression(this, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitReadPropExpr = function (ast, context) { - return this.transformExpr(new ReadPropExpr(ast.receiver.visitExpression(this, context), ast.name, ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitReadKeyExpr = function (ast, context) { - return this.transformExpr(new ReadKeyExpr(ast.receiver.visitExpression(this, context), ast.index.visitExpression(this, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitLiteralArrayExpr = function (ast, context) { - return this.transformExpr(new LiteralArrayExpr(this.visitAllExpressions(ast.entries, context), ast.type, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitLiteralMapExpr = function (ast, context) { - var _this = this; - var entries = ast.entries.map(function (entry) { return new LiteralMapEntry(entry.key, entry.value.visitExpression(_this, context), entry.quoted); }); - var mapType = new MapType(ast.valueType, null); - return this.transformExpr(new LiteralMapExpr(entries, mapType, ast.sourceSpan), context); - }; - AstTransformer.prototype.visitCommaExpr = function (ast, context) { - return this.transformExpr(new CommaExpr(this.visitAllExpressions(ast.parts, context), ast.sourceSpan), context); - }; - AstTransformer.prototype.visitAllExpressions = function (exprs, context) { - var _this = this; - return exprs.map(function (expr) { return expr.visitExpression(_this, context); }); - }; - AstTransformer.prototype.visitDeclareVarStmt = function (stmt, context) { - var value = stmt.value && stmt.value.visitExpression(this, context); - return this.transformStmt(new DeclareVarStmt(stmt.name, value, stmt.type, stmt.modifiers, stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitDeclareFunctionStmt = function (stmt, context) { - return this.transformStmt(new DeclareFunctionStmt(stmt.name, stmt.params, this.visitAllStatements(stmt.statements, context), stmt.type, stmt.modifiers, stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitExpressionStmt = function (stmt, context) { - return this.transformStmt(new ExpressionStatement(stmt.expr.visitExpression(this, context), stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitReturnStmt = function (stmt, context) { - return this.transformStmt(new ReturnStatement(stmt.value.visitExpression(this, context), stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitDeclareClassStmt = function (stmt, context) { - var _this = this; - var parent = stmt.parent.visitExpression(this, context); - var getters = stmt.getters.map(function (getter) { return new ClassGetter(getter.name, _this.visitAllStatements(getter.body, context), getter.type, getter.modifiers); }); - var ctorMethod = stmt.constructorMethod && - new ClassMethod(stmt.constructorMethod.name, stmt.constructorMethod.params, this.visitAllStatements(stmt.constructorMethod.body, context), stmt.constructorMethod.type, stmt.constructorMethod.modifiers); - var methods = stmt.methods.map(function (method) { return new ClassMethod(method.name, method.params, _this.visitAllStatements(method.body, context), method.type, method.modifiers); }); - return this.transformStmt(new ClassStmt(stmt.name, parent, stmt.fields, getters, ctorMethod, methods, stmt.modifiers, stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitIfStmt = function (stmt, context) { - return this.transformStmt(new IfStmt(stmt.condition.visitExpression(this, context), this.visitAllStatements(stmt.trueCase, context), this.visitAllStatements(stmt.falseCase, context), stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitTryCatchStmt = function (stmt, context) { - return this.transformStmt(new TryCatchStmt(this.visitAllStatements(stmt.bodyStmts, context), this.visitAllStatements(stmt.catchStmts, context), stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitThrowStmt = function (stmt, context) { - return this.transformStmt(new ThrowStmt(stmt.error.visitExpression(this, context), stmt.sourceSpan), context); - }; - AstTransformer.prototype.visitCommentStmt = function (stmt, context) { - return this.transformStmt(stmt, context); - }; - AstTransformer.prototype.visitJSDocCommentStmt = function (stmt, context) { - return this.transformStmt(stmt, context); - }; - AstTransformer.prototype.visitAllStatements = function (stmts, context) { - var _this = this; - return stmts.map(function (stmt) { return stmt.visitStatement(_this, context); }); - }; - return AstTransformer; -}()); -var RecursiveAstVisitor = /** @class */ (function () { - function RecursiveAstVisitor() { - } - RecursiveAstVisitor.prototype.visitType = function (ast, context) { return ast; }; - RecursiveAstVisitor.prototype.visitExpression = function (ast, context) { - if (ast.type) { - ast.type.visitType(this, context); - } - return ast; - }; - RecursiveAstVisitor.prototype.visitBuiltinType = function (type, context) { return this.visitType(type, context); }; - RecursiveAstVisitor.prototype.visitExpressionType = function (type, context) { - var _this = this; - type.value.visitExpression(this, context); - if (type.typeParams !== null) { - type.typeParams.forEach(function (param) { return _this.visitType(param, context); }); - } - return this.visitType(type, context); - }; - RecursiveAstVisitor.prototype.visitArrayType = function (type, context) { return this.visitType(type, context); }; - RecursiveAstVisitor.prototype.visitMapType = function (type, context) { return this.visitType(type, context); }; - RecursiveAstVisitor.prototype.visitWrappedNodeExpr = function (ast, context) { return ast; }; - RecursiveAstVisitor.prototype.visitTypeofExpr = function (ast, context) { return this.visitExpression(ast, context); }; - RecursiveAstVisitor.prototype.visitReadVarExpr = function (ast, context) { - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitWriteVarExpr = function (ast, context) { - ast.value.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitWriteKeyExpr = function (ast, context) { - ast.receiver.visitExpression(this, context); - ast.index.visitExpression(this, context); - ast.value.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitWritePropExpr = function (ast, context) { - ast.receiver.visitExpression(this, context); - ast.value.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitInvokeMethodExpr = function (ast, context) { - ast.receiver.visitExpression(this, context); - this.visitAllExpressions(ast.args, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitInvokeFunctionExpr = function (ast, context) { - ast.fn.visitExpression(this, context); - this.visitAllExpressions(ast.args, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitInstantiateExpr = function (ast, context) { - ast.classExpr.visitExpression(this, context); - this.visitAllExpressions(ast.args, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitLiteralExpr = function (ast, context) { - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitExternalExpr = function (ast, context) { - var _this = this; - if (ast.typeParams) { - ast.typeParams.forEach(function (type) { return type.visitType(_this, context); }); - } - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitConditionalExpr = function (ast, context) { - ast.condition.visitExpression(this, context); - ast.trueCase.visitExpression(this, context); - ast.falseCase.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitNotExpr = function (ast, context) { - ast.condition.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitAssertNotNullExpr = function (ast, context) { - ast.condition.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitCastExpr = function (ast, context) { - ast.value.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitFunctionExpr = function (ast, context) { - this.visitAllStatements(ast.statements, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitBinaryOperatorExpr = function (ast, context) { - ast.lhs.visitExpression(this, context); - ast.rhs.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitReadPropExpr = function (ast, context) { - ast.receiver.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitReadKeyExpr = function (ast, context) { - ast.receiver.visitExpression(this, context); - ast.index.visitExpression(this, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitLiteralArrayExpr = function (ast, context) { - this.visitAllExpressions(ast.entries, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitLiteralMapExpr = function (ast, context) { - var _this = this; - ast.entries.forEach(function (entry) { return entry.value.visitExpression(_this, context); }); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitCommaExpr = function (ast, context) { - this.visitAllExpressions(ast.parts, context); - return this.visitExpression(ast, context); - }; - RecursiveAstVisitor.prototype.visitAllExpressions = function (exprs, context) { - var _this = this; - exprs.forEach(function (expr) { return expr.visitExpression(_this, context); }); - }; - RecursiveAstVisitor.prototype.visitDeclareVarStmt = function (stmt, context) { - if (stmt.value) { - stmt.value.visitExpression(this, context); - } - if (stmt.type) { - stmt.type.visitType(this, context); - } - return stmt; - }; - RecursiveAstVisitor.prototype.visitDeclareFunctionStmt = function (stmt, context) { - this.visitAllStatements(stmt.statements, context); - if (stmt.type) { - stmt.type.visitType(this, context); - } - return stmt; - }; - RecursiveAstVisitor.prototype.visitExpressionStmt = function (stmt, context) { - stmt.expr.visitExpression(this, context); - return stmt; - }; - RecursiveAstVisitor.prototype.visitReturnStmt = function (stmt, context) { - stmt.value.visitExpression(this, context); - return stmt; - }; - RecursiveAstVisitor.prototype.visitDeclareClassStmt = function (stmt, context) { - var _this = this; - stmt.parent.visitExpression(this, context); - stmt.getters.forEach(function (getter) { return _this.visitAllStatements(getter.body, context); }); - if (stmt.constructorMethod) { - this.visitAllStatements(stmt.constructorMethod.body, context); - } - stmt.methods.forEach(function (method) { return _this.visitAllStatements(method.body, context); }); - return stmt; - }; - RecursiveAstVisitor.prototype.visitIfStmt = function (stmt, context) { - stmt.condition.visitExpression(this, context); - this.visitAllStatements(stmt.trueCase, context); - this.visitAllStatements(stmt.falseCase, context); - return stmt; - }; - RecursiveAstVisitor.prototype.visitTryCatchStmt = function (stmt, context) { - this.visitAllStatements(stmt.bodyStmts, context); - this.visitAllStatements(stmt.catchStmts, context); - return stmt; - }; - RecursiveAstVisitor.prototype.visitThrowStmt = function (stmt, context) { - stmt.error.visitExpression(this, context); - return stmt; - }; - RecursiveAstVisitor.prototype.visitCommentStmt = function (stmt, context) { return stmt; }; - RecursiveAstVisitor.prototype.visitJSDocCommentStmt = function (stmt, context) { return stmt; }; - RecursiveAstVisitor.prototype.visitAllStatements = function (stmts, context) { - var _this = this; - stmts.forEach(function (stmt) { return stmt.visitStatement(_this, context); }); - }; - return RecursiveAstVisitor; -}()); -function findReadVarNames(stmts) { - var visitor = new _ReadVarVisitor(); - visitor.visitAllStatements(stmts, null); - return visitor.varNames; -} -var _ReadVarVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(_ReadVarVisitor, _super); - function _ReadVarVisitor() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this.varNames = new Set(); - return _this; - } - _ReadVarVisitor.prototype.visitDeclareFunctionStmt = function (stmt, context) { - // Don't descend into nested functions - return stmt; - }; - _ReadVarVisitor.prototype.visitDeclareClassStmt = function (stmt, context) { - // Don't descend into nested classes - return stmt; - }; - _ReadVarVisitor.prototype.visitReadVarExpr = function (ast, context) { - if (ast.name) { - this.varNames.add(ast.name); - } - return null; - }; - return _ReadVarVisitor; -}(RecursiveAstVisitor)); -function collectExternalReferences(stmts) { - var visitor = new _FindExternalReferencesVisitor(); - visitor.visitAllStatements(stmts, null); - return visitor.externalReferences; -} -var _FindExternalReferencesVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(_FindExternalReferencesVisitor, _super); - function _FindExternalReferencesVisitor() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this.externalReferences = []; - return _this; - } - _FindExternalReferencesVisitor.prototype.visitExternalExpr = function (e, context) { - this.externalReferences.push(e.value); - return _super.prototype.visitExternalExpr.call(this, e, context); - }; - return _FindExternalReferencesVisitor; -}(RecursiveAstVisitor)); -function applySourceSpanToStatementIfNeeded(stmt, sourceSpan) { - if (!sourceSpan) { - return stmt; - } - var transformer = new _ApplySourceSpanTransformer(sourceSpan); - return stmt.visitStatement(transformer, null); -} -function applySourceSpanToExpressionIfNeeded(expr, sourceSpan) { - if (!sourceSpan) { - return expr; - } - var transformer = new _ApplySourceSpanTransformer(sourceSpan); - return expr.visitExpression(transformer, null); -} -var _ApplySourceSpanTransformer = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(_ApplySourceSpanTransformer, _super); - function _ApplySourceSpanTransformer(sourceSpan) { - var _this = _super.call(this) || this; - _this.sourceSpan = sourceSpan; - return _this; - } - _ApplySourceSpanTransformer.prototype._clone = function (obj) { - var e_1, _a; - var clone = Object.create(obj.constructor.prototype); - try { - for (var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(Object.keys(obj)), _c = _b.next(); !_c.done; _c = _b.next()) { - var prop = _c.value; - clone[prop] = obj[prop]; - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (_c && !_c.done && (_a = _b.return)) _a.call(_b); - } - finally { if (e_1) throw e_1.error; } - } - return clone; - }; - _ApplySourceSpanTransformer.prototype.transformExpr = function (expr, context) { - if (!expr.sourceSpan) { - expr = this._clone(expr); - expr.sourceSpan = this.sourceSpan; - } - return expr; - }; - _ApplySourceSpanTransformer.prototype.transformStmt = function (stmt, context) { - if (!stmt.sourceSpan) { - stmt = this._clone(stmt); - stmt.sourceSpan = this.sourceSpan; - } - return stmt; - }; - return _ApplySourceSpanTransformer; -}(AstTransformer)); -function variable(name, type, sourceSpan) { - return new ReadVarExpr(name, type, sourceSpan); -} -function importExpr(id, typeParams, sourceSpan) { - if (typeParams === void 0) { typeParams = null; } - return new ExternalExpr(id, null, typeParams, sourceSpan); -} -function importType(id, typeParams, typeModifiers) { - if (typeParams === void 0) { typeParams = null; } - if (typeModifiers === void 0) { typeModifiers = null; } - return id != null ? expressionType(importExpr(id, typeParams, null), typeModifiers) : null; -} -function expressionType(expr, typeModifiers, typeParams) { - if (typeModifiers === void 0) { typeModifiers = null; } - if (typeParams === void 0) { typeParams = null; } - return new ExpressionType(expr, typeModifiers, typeParams); -} -function typeofExpr(expr) { - return new TypeofExpr(expr); -} -function literalArr(values, type, sourceSpan) { - return new LiteralArrayExpr(values, type, sourceSpan); -} -function literalMap(values, type) { - if (type === void 0) { type = null; } - return new LiteralMapExpr(values.map(function (e) { return new LiteralMapEntry(e.key, e.value, e.quoted); }), type, null); -} -function not(expr, sourceSpan) { - return new NotExpr(expr, sourceSpan); -} -function assertNotNull(expr, sourceSpan) { - return new AssertNotNull(expr, sourceSpan); -} -function fn(params, body, type, sourceSpan, name) { - return new FunctionExpr(params, body, type, sourceSpan, name); -} -function ifStmt(condition, thenClause, elseClause) { - return new IfStmt(condition, thenClause, elseClause); -} -function literal(value, type, sourceSpan) { - return new LiteralExpr(value, type, sourceSpan); -} -function isNull(exp) { - return exp instanceof LiteralExpr && exp.value === null; -} -/* - * Serializes a `Tag` into a string. - * Returns a string like " @foo {bar} baz" (note the leading whitespace before `@foo`). - */ -function tagToString(tag) { - var out = ''; - if (tag.tagName) { - out += " @" + tag.tagName; - } - if (tag.text) { - if (tag.text.match(/\/\*|\*\//)) { - throw new Error('JSDoc text cannot contain "/*" and "*/"'); - } - out += ' ' + tag.text.replace(/@/g, '\\@'); - } - return out; -} -function serializeTags(tags) { - var e_2, _a; - if (tags.length === 0) - return ''; - var out = '*\n'; - try { - for (var tags_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(tags), tags_1_1 = tags_1.next(); !tags_1_1.done; tags_1_1 = tags_1.next()) { - var tag = tags_1_1.value; - out += ' *'; - // If the tagToString is multi-line, insert " * " prefixes on subsequent lines. - out += tagToString(tag).replace(/\n/g, '\n * '); - out += '\n'; - } - } - catch (e_2_1) { e_2 = { error: e_2_1 }; } - finally { - try { - if (tags_1_1 && !tags_1_1.done && (_a = tags_1.return)) _a.call(tags_1); - } - finally { if (e_2) throw e_2.error; } - } - out += ' '; - return out; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var DASH_CASE_REGEXP = /-+([a-z0-9])/g; -function dashCaseToCamelCase(input) { - return input.replace(DASH_CASE_REGEXP, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - return m[1].toUpperCase(); - }); -} -function splitAtColon(input, defaultValues) { - return _splitAt(input, ':', defaultValues); -} -function splitAtPeriod(input, defaultValues) { - return _splitAt(input, '.', defaultValues); -} -function _splitAt(input, character, defaultValues) { - var characterIndex = input.indexOf(character); - if (characterIndex == -1) - return defaultValues; - return [input.slice(0, characterIndex).trim(), input.slice(characterIndex + 1).trim()]; -} -function visitValue(value, visitor, context) { - if (Array.isArray(value)) { - return visitor.visitArray(value, context); - } - if (isStrictStringMap(value)) { - return visitor.visitStringMap(value, context); - } - if (value == null || typeof value == 'string' || typeof value == 'number' || - typeof value == 'boolean') { - return visitor.visitPrimitive(value, context); - } - return visitor.visitOther(value, context); -} -function isDefined(val) { - return val !== null && val !== undefined; -} -function noUndefined(val) { - return val === undefined ? null : val; -} -var ValueTransformer = /** @class */ (function () { - function ValueTransformer() { - } - ValueTransformer.prototype.visitArray = function (arr, context) { - var _this = this; - return arr.map(function (value) { return visitValue(value, _this, context); }); - }; - ValueTransformer.prototype.visitStringMap = function (map, context) { - var _this = this; - var result = {}; - Object.keys(map).forEach(function (key) { result[key] = visitValue(map[key], _this, context); }); - return result; - }; - ValueTransformer.prototype.visitPrimitive = function (value, context) { return value; }; - ValueTransformer.prototype.visitOther = function (value, context) { return value; }; - return ValueTransformer; -}()); -var SyncAsync = { - assertSync: function (value) { - if (isPromise(value)) { - throw new Error("Illegal state: value cannot be a promise"); - } - return value; - }, - then: function (value, cb) { return isPromise(value) ? value.then(cb) : cb(value); }, - all: function (syncAsyncValues) { - return syncAsyncValues.some(isPromise) ? Promise.all(syncAsyncValues) : syncAsyncValues; - } -}; -function error(msg) { - throw new Error("Internal Error: " + msg); -} -function syntaxError(msg, parseErrors) { - var error = Error(msg); - error[ERROR_SYNTAX_ERROR] = true; - if (parseErrors) - error[ERROR_PARSE_ERRORS] = parseErrors; - return error; -} -var ERROR_SYNTAX_ERROR = 'ngSyntaxError'; -var ERROR_PARSE_ERRORS = 'ngParseErrors'; -function isSyntaxError(error) { - return error[ERROR_SYNTAX_ERROR]; -} -function getParseErrors(error) { - return error[ERROR_PARSE_ERRORS] || []; -} -// Escape characters that have a special meaning in Regular Expressions -function escapeRegExp(s) { - return s.replace(/([.*+?^=!:${}()|[\]\/\\])/g, '\\$1'); -} -var STRING_MAP_PROTO = Object.getPrototypeOf({}); -function isStrictStringMap(obj) { - return typeof obj === 'object' && obj !== null && Object.getPrototypeOf(obj) === STRING_MAP_PROTO; -} -function utf8Encode(str) { - var encoded = ''; - for (var index = 0; index < str.length; index++) { - var codePoint = str.charCodeAt(index); - // decode surrogate - // see https://mathiasbynens.be/notes/javascript-encoding#surrogate-formulae - if (codePoint >= 0xd800 && codePoint <= 0xdbff && str.length > (index + 1)) { - var low = str.charCodeAt(index + 1); - if (low >= 0xdc00 && low <= 0xdfff) { - index++; - codePoint = ((codePoint - 0xd800) << 10) + low - 0xdc00 + 0x10000; - } - } - if (codePoint <= 0x7f) { - encoded += String.fromCharCode(codePoint); - } - else if (codePoint <= 0x7ff) { - encoded += String.fromCharCode(((codePoint >> 6) & 0x1F) | 0xc0, (codePoint & 0x3f) | 0x80); - } - else if (codePoint <= 0xffff) { - encoded += String.fromCharCode((codePoint >> 12) | 0xe0, ((codePoint >> 6) & 0x3f) | 0x80, (codePoint & 0x3f) | 0x80); - } - else if (codePoint <= 0x1fffff) { - encoded += String.fromCharCode(((codePoint >> 18) & 0x07) | 0xf0, ((codePoint >> 12) & 0x3f) | 0x80, ((codePoint >> 6) & 0x3f) | 0x80, (codePoint & 0x3f) | 0x80); - } - } - return encoded; -} -function stringify(token) { - if (typeof token === 'string') { - return token; - } - if (token instanceof Array) { - return '[' + token.map(stringify).join(', ') + ']'; - } - if (token == null) { - return '' + token; - } - if (token.overriddenName) { - return "" + token.overriddenName; - } - if (token.name) { - return "" + token.name; - } - if (!token.toString) { - return 'object'; - } - // WARNING: do not try to `JSON.stringify(token)` here - // see https://github.com/angular/angular/issues/23440 - var res = token.toString(); - if (res == null) { - return '' + res; - } - var newLineIndex = res.indexOf('\n'); - return newLineIndex === -1 ? res : res.substring(0, newLineIndex); -} -/** - * Lazily retrieves the reference value from a forwardRef. - */ -function resolveForwardRef(type) { - if (typeof type === 'function' && type.hasOwnProperty('__forward_ref__')) { - return type(); - } - else { - return type; - } -} -/** - * Determine if the argument is shaped like a Promise - */ -function isPromise(obj) { - // allow any Promise/A+ compliant thenable. - // It's up to the caller to ensure that obj.then conforms to the spec - return !!obj && typeof obj.then === 'function'; -} -var Version = /** @class */ (function () { - function Version(full) { - this.full = full; - var splits = full.split('.'); - this.major = splits[0]; - this.minor = splits[1]; - this.patch = splits.slice(2).join('.'); - } - return Version; -}()); -var __window = typeof window !== 'undefined' && window; -var __self = typeof self !== 'undefined' && typeof WorkerGlobalScope !== 'undefined' && - self instanceof WorkerGlobalScope && self; -var __global = typeof global !== 'undefined' && global; -// Check __global first, because in Node tests both __global and __window may be defined and _global -// should be __global in that case. -var _global = __global || __window || __self; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var CONSTANT_PREFIX = '_c'; -/** - * Context to use when producing a key. - * - * This ensures we see the constant not the reference variable when producing - * a key. - */ -var KEY_CONTEXT = {}; -/** - * A node that is a place-holder that allows the node to be replaced when the actual - * node is known. - * - * This allows the constant pool to change an expression from a direct reference to - * a constant to a shared constant. It returns a fix-up node that is later allowed to - * change the referenced expression. - */ -var FixupExpression = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(FixupExpression, _super); - function FixupExpression(resolved) { - var _this = _super.call(this, resolved.type) || this; - _this.resolved = resolved; - _this.original = resolved; - return _this; - } - FixupExpression.prototype.visitExpression = function (visitor, context) { - if (context === KEY_CONTEXT) { - // When producing a key we want to traverse the constant not the - // variable used to refer to it. - return this.original.visitExpression(visitor, context); - } - else { - return this.resolved.visitExpression(visitor, context); - } - }; - FixupExpression.prototype.isEquivalent = function (e) { - return e instanceof FixupExpression && this.resolved.isEquivalent(e.resolved); - }; - FixupExpression.prototype.isConstant = function () { return true; }; - FixupExpression.prototype.fixup = function (expression) { - this.resolved = expression; - this.shared = true; - }; - return FixupExpression; -}(Expression)); -/** - * A constant pool allows a code emitter to share constant in an output context. - * - * The constant pool also supports sharing access to ivy definitions references. - */ -var ConstantPool = /** @class */ (function () { - function ConstantPool() { - this.statements = []; - this.literals = new Map(); - this.literalFactories = new Map(); - this.injectorDefinitions = new Map(); - this.directiveDefinitions = new Map(); - this.componentDefinitions = new Map(); - this.pipeDefinitions = new Map(); - this.nextNameIndex = 0; - } - ConstantPool.prototype.getConstLiteral = function (literal, forceShared) { - if (literal instanceof LiteralExpr || literal instanceof FixupExpression) { - // Do no put simple literals into the constant pool or try to produce a constant for a - // reference to a constant. - return literal; - } - var key = this.keyOf(literal); - var fixup = this.literals.get(key); - var newValue = false; - if (!fixup) { - fixup = new FixupExpression(literal); - this.literals.set(key, fixup); - newValue = true; - } - if ((!newValue && !fixup.shared) || (newValue && forceShared)) { - // Replace the expression with a variable - var name_1 = this.freshName(); - this.statements.push(variable(name_1).set(literal).toDeclStmt(INFERRED_TYPE, [StmtModifier.Final])); - fixup.fixup(variable(name_1)); - } - return fixup; - }; - ConstantPool.prototype.getDefinition = function (type, kind, ctx, forceShared) { - if (forceShared === void 0) { forceShared = false; } - var definitions = this.definitionsOf(kind); - var fixup = definitions.get(type); - var newValue = false; - if (!fixup) { - var property = this.propertyNameOf(kind); - fixup = new FixupExpression(ctx.importExpr(type).prop(property)); - definitions.set(type, fixup); - newValue = true; - } - if ((!newValue && !fixup.shared) || (newValue && forceShared)) { - var name_2 = this.freshName(); - this.statements.push(variable(name_2).set(fixup.resolved).toDeclStmt(INFERRED_TYPE, [StmtModifier.Final])); - fixup.fixup(variable(name_2)); - } - return fixup; - }; - ConstantPool.prototype.getLiteralFactory = function (literal$1) { - // Create a pure function that builds an array of a mix of constant and variable expressions - if (literal$1 instanceof LiteralArrayExpr) { - var argumentsForKey = literal$1.entries.map(function (e) { return e.isConstant() ? e : literal(null); }); - var key = this.keyOf(literalArr(argumentsForKey)); - return this._getLiteralFactory(key, literal$1.entries, function (entries) { return literalArr(entries); }); - } - else { - var expressionForKey = literalMap(literal$1.entries.map(function (e) { return ({ - key: e.key, - value: e.value.isConstant() ? e.value : literal(null), - quoted: e.quoted - }); })); - var key = this.keyOf(expressionForKey); - return this._getLiteralFactory(key, literal$1.entries.map(function (e) { return e.value; }), function (entries) { return literalMap(entries.map(function (value, index) { return ({ - key: literal$1.entries[index].key, - value: value, - quoted: literal$1.entries[index].quoted - }); })); }); - } - }; - ConstantPool.prototype._getLiteralFactory = function (key, values, resultMap) { - var _this = this; - var literalFactory = this.literalFactories.get(key); - var literalFactoryArguments = values.filter((function (e) { return !e.isConstant(); })); - if (!literalFactory) { - var resultExpressions = values.map(function (e, index) { return e.isConstant() ? _this.getConstLiteral(e, true) : variable("a" + index); }); - var parameters = resultExpressions.filter(isVariable).map(function (e) { return new FnParam(e.name, DYNAMIC_TYPE); }); - var pureFunctionDeclaration = fn(parameters, [new ReturnStatement(resultMap(resultExpressions))], INFERRED_TYPE); - var name_3 = this.freshName(); - this.statements.push(variable(name_3).set(pureFunctionDeclaration).toDeclStmt(INFERRED_TYPE, [ - StmtModifier.Final - ])); - literalFactory = variable(name_3); - this.literalFactories.set(key, literalFactory); - } - return { literalFactory: literalFactory, literalFactoryArguments: literalFactoryArguments }; - }; - /** - * Produce a unique name. - * - * The name might be unique among different prefixes if any of the prefixes end in - * a digit so the prefix should be a constant string (not based on user input) and - * must not end in a digit. - */ - ConstantPool.prototype.uniqueName = function (prefix) { return "" + prefix + this.nextNameIndex++; }; - ConstantPool.prototype.definitionsOf = function (kind) { - switch (kind) { - case 2 /* Component */: - return this.componentDefinitions; - case 1 /* Directive */: - return this.directiveDefinitions; - case 0 /* Injector */: - return this.injectorDefinitions; - case 3 /* Pipe */: - return this.pipeDefinitions; - } - error("Unknown definition kind " + kind); - return this.componentDefinitions; - }; - ConstantPool.prototype.propertyNameOf = function (kind) { - switch (kind) { - case 2 /* Component */: - return 'ngComponentDef'; - case 1 /* Directive */: - return 'ngDirectiveDef'; - case 0 /* Injector */: - return 'ngInjectorDef'; - case 3 /* Pipe */: - return 'ngPipeDef'; - } - error("Unknown definition kind " + kind); - return ''; - }; - ConstantPool.prototype.freshName = function () { return this.uniqueName(CONSTANT_PREFIX); }; - ConstantPool.prototype.keyOf = function (expression) { - return expression.visitExpression(new KeyVisitor(), KEY_CONTEXT); - }; - return ConstantPool; -}()); -/** - * Visitor used to determine if 2 expressions are equivalent and can be shared in the - * `ConstantPool`. - * - * When the id (string) generated by the visitor is equal, expressions are considered equivalent. - */ -var KeyVisitor = /** @class */ (function () { - function KeyVisitor() { - this.visitWrappedNodeExpr = invalid; - this.visitWriteVarExpr = invalid; - this.visitWriteKeyExpr = invalid; - this.visitWritePropExpr = invalid; - this.visitInvokeMethodExpr = invalid; - this.visitInvokeFunctionExpr = invalid; - this.visitInstantiateExpr = invalid; - this.visitConditionalExpr = invalid; - this.visitNotExpr = invalid; - this.visitAssertNotNullExpr = invalid; - this.visitCastExpr = invalid; - this.visitFunctionExpr = invalid; - this.visitBinaryOperatorExpr = invalid; - this.visitReadPropExpr = invalid; - this.visitReadKeyExpr = invalid; - this.visitCommaExpr = invalid; - } - KeyVisitor.prototype.visitLiteralExpr = function (ast) { - return "" + (typeof ast.value === 'string' ? '"' + ast.value + '"' : ast.value); - }; - KeyVisitor.prototype.visitLiteralArrayExpr = function (ast, context) { - var _this = this; - return "[" + ast.entries.map(function (entry) { return entry.visitExpression(_this, context); }).join(',') + "]"; - }; - KeyVisitor.prototype.visitLiteralMapExpr = function (ast, context) { - var _this = this; - var mapKey = function (entry) { - var quote = entry.quoted ? '"' : ''; - return "" + quote + entry.key + quote; - }; - var mapEntry = function (entry) { - return mapKey(entry) + ":" + entry.value.visitExpression(_this, context); - }; - return "{" + ast.entries.map(mapEntry).join(','); - }; - KeyVisitor.prototype.visitExternalExpr = function (ast) { - return ast.value.moduleName ? "EX:" + ast.value.moduleName + ":" + ast.value.name : - "EX:" + ast.value.runtime.name; - }; - KeyVisitor.prototype.visitReadVarExpr = function (node) { return "VAR:" + node.name; }; - KeyVisitor.prototype.visitTypeofExpr = function (node, context) { - return "TYPEOF:" + node.expr.visitExpression(this, context); - }; - return KeyVisitor; -}()); -function invalid(arg) { - throw new Error("Invalid state: Visitor " + this.constructor.name + " doesn't handle " + arg.constructor.name); -} -function isVariable(e) { - return e instanceof ReadVarExpr; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var CORE = '@angular/core'; -var Identifiers = /** @class */ (function () { - function Identifiers() { - } - Identifiers.ANALYZE_FOR_ENTRY_COMPONENTS = { - name: 'ANALYZE_FOR_ENTRY_COMPONENTS', - moduleName: CORE, - }; - Identifiers.ElementRef = { name: 'ElementRef', moduleName: CORE }; - Identifiers.NgModuleRef = { name: 'NgModuleRef', moduleName: CORE }; - Identifiers.ViewContainerRef = { name: 'ViewContainerRef', moduleName: CORE }; - Identifiers.ChangeDetectorRef = { - name: 'ChangeDetectorRef', - moduleName: CORE, - }; - Identifiers.QueryList = { name: 'QueryList', moduleName: CORE }; - Identifiers.TemplateRef = { name: 'TemplateRef', moduleName: CORE }; - Identifiers.Renderer2 = { name: 'Renderer2', moduleName: CORE }; - Identifiers.CodegenComponentFactoryResolver = { - name: 'ɵCodegenComponentFactoryResolver', - moduleName: CORE, - }; - Identifiers.ComponentFactoryResolver = { - name: 'ComponentFactoryResolver', - moduleName: CORE, - }; - Identifiers.ComponentFactory = { name: 'ComponentFactory', moduleName: CORE }; - Identifiers.ComponentRef = { name: 'ComponentRef', moduleName: CORE }; - Identifiers.NgModuleFactory = { name: 'NgModuleFactory', moduleName: CORE }; - Identifiers.createModuleFactory = { - name: 'ɵcmf', - moduleName: CORE, - }; - Identifiers.moduleDef = { - name: 'ɵmod', - moduleName: CORE, - }; - Identifiers.moduleProviderDef = { - name: 'ɵmpd', - moduleName: CORE, - }; - Identifiers.RegisterModuleFactoryFn = { - name: 'ɵregisterModuleFactory', - moduleName: CORE, - }; - Identifiers.inject = { name: 'ɵɵinject', moduleName: CORE }; - Identifiers.INJECTOR = { name: 'INJECTOR', moduleName: CORE }; - Identifiers.Injector = { name: 'Injector', moduleName: CORE }; - Identifiers.ɵɵdefineInjectable = { name: 'ɵɵdefineInjectable', moduleName: CORE }; - Identifiers.InjectableDef = { name: 'ɵɵInjectableDef', moduleName: CORE }; - Identifiers.ViewEncapsulation = { - name: 'ViewEncapsulation', - moduleName: CORE, - }; - Identifiers.ChangeDetectionStrategy = { - name: 'ChangeDetectionStrategy', - moduleName: CORE, - }; - Identifiers.SecurityContext = { - name: 'SecurityContext', - moduleName: CORE, - }; - Identifiers.LOCALE_ID = { name: 'LOCALE_ID', moduleName: CORE }; - Identifiers.TRANSLATIONS_FORMAT = { - name: 'TRANSLATIONS_FORMAT', - moduleName: CORE, - }; - Identifiers.inlineInterpolate = { - name: 'ɵinlineInterpolate', - moduleName: CORE, - }; - Identifiers.interpolate = { name: 'ɵinterpolate', moduleName: CORE }; - Identifiers.EMPTY_ARRAY = { name: 'ɵEMPTY_ARRAY', moduleName: CORE }; - Identifiers.EMPTY_MAP = { name: 'ɵEMPTY_MAP', moduleName: CORE }; - Identifiers.Renderer = { name: 'Renderer', moduleName: CORE }; - Identifiers.viewDef = { name: 'ɵvid', moduleName: CORE }; - Identifiers.elementDef = { name: 'ɵeld', moduleName: CORE }; - Identifiers.anchorDef = { name: 'ɵand', moduleName: CORE }; - Identifiers.textDef = { name: 'ɵted', moduleName: CORE }; - Identifiers.directiveDef = { name: 'ɵdid', moduleName: CORE }; - Identifiers.providerDef = { name: 'ɵprd', moduleName: CORE }; - Identifiers.queryDef = { name: 'ɵqud', moduleName: CORE }; - Identifiers.pureArrayDef = { name: 'ɵpad', moduleName: CORE }; - Identifiers.pureObjectDef = { name: 'ɵpod', moduleName: CORE }; - Identifiers.purePipeDef = { name: 'ɵppd', moduleName: CORE }; - Identifiers.pipeDef = { name: 'ɵpid', moduleName: CORE }; - Identifiers.nodeValue = { name: 'ɵnov', moduleName: CORE }; - Identifiers.ngContentDef = { name: 'ɵncd', moduleName: CORE }; - Identifiers.unwrapValue = { name: 'ɵunv', moduleName: CORE }; - Identifiers.createRendererType2 = { name: 'ɵcrt', moduleName: CORE }; - // type only - Identifiers.RendererType2 = { - name: 'RendererType2', - moduleName: CORE, - }; - // type only - Identifiers.ViewDefinition = { - name: 'ɵViewDefinition', - moduleName: CORE, - }; - Identifiers.createComponentFactory = { name: 'ɵccf', moduleName: CORE }; - Identifiers.setClassMetadata = { name: 'ɵsetClassMetadata', moduleName: CORE }; - return Identifiers; -}()); -function createTokenForReference(reference) { - return { identifier: { reference: reference } }; -} -function createTokenForExternalReference(reflector, reference) { - return createTokenForReference(reflector.resolveExternalReference(reference)); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A token representing the a reference to a static type. - * - * This token is unique for a filePath and name and can be used as a hash table key. - */ -var StaticSymbol = /** @class */ (function () { - function StaticSymbol(filePath, name, members) { - this.filePath = filePath; - this.name = name; - this.members = members; - } - StaticSymbol.prototype.assertNoMembers = function () { - if (this.members.length) { - throw new Error("Illegal state: symbol without members expected, but got " + JSON.stringify(this) + "."); - } - }; - return StaticSymbol; -}()); -/** - * A cache of static symbol used by the StaticReflector to return the same symbol for the - * same symbol values. - */ -var StaticSymbolCache = /** @class */ (function () { - function StaticSymbolCache() { - this.cache = new Map(); - } - StaticSymbolCache.prototype.get = function (declarationFile, name, members) { - members = members || []; - var memberSuffix = members.length ? "." + members.join('.') : ''; - var key = "\"" + declarationFile + "\"." + name + memberSuffix; - var result = this.cache.get(key); - if (!result) { - result = new StaticSymbol(declarationFile, name, members); - this.cache.set(key, result); - } - return result; - }; - return StaticSymbolCache; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// group 0: "[prop] or (event) or @trigger" -// group 1: "prop" from "[prop]" -// group 2: "event" from "(event)" -// group 3: "@trigger" from "@trigger" -var HOST_REG_EXP = /^(?:(?:\[([^\]]+)\])|(?:\(([^\)]+)\)))|(\@[-\w]+)$/; -function sanitizeIdentifier(name) { - return name.replace(/\W/g, '_'); -} -var _anonymousTypeIndex = 0; -function identifierName(compileIdentifier) { - if (!compileIdentifier || !compileIdentifier.reference) { - return null; - } - var ref = compileIdentifier.reference; - if (ref instanceof StaticSymbol) { - return ref.name; - } - if (ref['__anonymousType']) { - return ref['__anonymousType']; - } - var identifier = stringify(ref); - if (identifier.indexOf('(') >= 0) { - // case: anonymous functions! - identifier = "anonymous_" + _anonymousTypeIndex++; - ref['__anonymousType'] = identifier; - } - else { - identifier = sanitizeIdentifier(identifier); - } - return identifier; -} -function identifierModuleUrl(compileIdentifier) { - var ref = compileIdentifier.reference; - if (ref instanceof StaticSymbol) { - return ref.filePath; - } - // Runtime type - return "./" + stringify(ref); -} -function viewClassName(compType, embeddedTemplateIndex) { - return "View_" + identifierName({ reference: compType }) + "_" + embeddedTemplateIndex; -} -function rendererTypeName(compType) { - return "RenderType_" + identifierName({ reference: compType }); -} -function hostViewClassName(compType) { - return "HostView_" + identifierName({ reference: compType }); -} -function componentFactoryName(compType) { - return identifierName({ reference: compType }) + "NgFactory"; -} -var CompileSummaryKind; -(function (CompileSummaryKind) { - CompileSummaryKind[CompileSummaryKind["Pipe"] = 0] = "Pipe"; - CompileSummaryKind[CompileSummaryKind["Directive"] = 1] = "Directive"; - CompileSummaryKind[CompileSummaryKind["NgModule"] = 2] = "NgModule"; - CompileSummaryKind[CompileSummaryKind["Injectable"] = 3] = "Injectable"; -})(CompileSummaryKind || (CompileSummaryKind = {})); -function tokenName(token) { - return token.value != null ? sanitizeIdentifier(token.value) : identifierName(token.identifier); -} -function tokenReference(token) { - if (token.identifier != null) { - return token.identifier.reference; - } - else { - return token.value; - } -} -/** - * Metadata about a stylesheet - */ -var CompileStylesheetMetadata = /** @class */ (function () { - function CompileStylesheetMetadata(_a) { - var _b = _a === void 0 ? {} : _a, moduleUrl = _b.moduleUrl, styles = _b.styles, styleUrls = _b.styleUrls; - this.moduleUrl = moduleUrl || null; - this.styles = _normalizeArray(styles); - this.styleUrls = _normalizeArray(styleUrls); - } - return CompileStylesheetMetadata; -}()); -/** - * Metadata regarding compilation of a template. - */ -var CompileTemplateMetadata = /** @class */ (function () { - function CompileTemplateMetadata(_a) { - var encapsulation = _a.encapsulation, template = _a.template, templateUrl = _a.templateUrl, htmlAst = _a.htmlAst, styles = _a.styles, styleUrls = _a.styleUrls, externalStylesheets = _a.externalStylesheets, animations = _a.animations, ngContentSelectors = _a.ngContentSelectors, interpolation = _a.interpolation, isInline = _a.isInline, preserveWhitespaces = _a.preserveWhitespaces; - this.encapsulation = encapsulation; - this.template = template; - this.templateUrl = templateUrl; - this.htmlAst = htmlAst; - this.styles = _normalizeArray(styles); - this.styleUrls = _normalizeArray(styleUrls); - this.externalStylesheets = _normalizeArray(externalStylesheets); - this.animations = animations ? flatten(animations) : []; - this.ngContentSelectors = ngContentSelectors || []; - if (interpolation && interpolation.length != 2) { - throw new Error("'interpolation' should have a start and an end symbol."); - } - this.interpolation = interpolation; - this.isInline = isInline; - this.preserveWhitespaces = preserveWhitespaces; - } - CompileTemplateMetadata.prototype.toSummary = function () { - return { - ngContentSelectors: this.ngContentSelectors, - encapsulation: this.encapsulation, - styles: this.styles, - animations: this.animations - }; - }; - return CompileTemplateMetadata; -}()); -/** - * Metadata regarding compilation of a directive. - */ -var CompileDirectiveMetadata = /** @class */ (function () { - function CompileDirectiveMetadata(_a) { - var isHost = _a.isHost, type = _a.type, isComponent = _a.isComponent, selector = _a.selector, exportAs = _a.exportAs, changeDetection = _a.changeDetection, inputs = _a.inputs, outputs = _a.outputs, hostListeners = _a.hostListeners, hostProperties = _a.hostProperties, hostAttributes = _a.hostAttributes, providers = _a.providers, viewProviders = _a.viewProviders, queries = _a.queries, guards = _a.guards, viewQueries = _a.viewQueries, entryComponents = _a.entryComponents, template = _a.template, componentViewType = _a.componentViewType, rendererType = _a.rendererType, componentFactory = _a.componentFactory; - this.isHost = !!isHost; - this.type = type; - this.isComponent = isComponent; - this.selector = selector; - this.exportAs = exportAs; - this.changeDetection = changeDetection; - this.inputs = inputs; - this.outputs = outputs; - this.hostListeners = hostListeners; - this.hostProperties = hostProperties; - this.hostAttributes = hostAttributes; - this.providers = _normalizeArray(providers); - this.viewProviders = _normalizeArray(viewProviders); - this.queries = _normalizeArray(queries); - this.guards = guards; - this.viewQueries = _normalizeArray(viewQueries); - this.entryComponents = _normalizeArray(entryComponents); - this.template = template; - this.componentViewType = componentViewType; - this.rendererType = rendererType; - this.componentFactory = componentFactory; - } - CompileDirectiveMetadata.create = function (_a) { - var isHost = _a.isHost, type = _a.type, isComponent = _a.isComponent, selector = _a.selector, exportAs = _a.exportAs, changeDetection = _a.changeDetection, inputs = _a.inputs, outputs = _a.outputs, host = _a.host, providers = _a.providers, viewProviders = _a.viewProviders, queries = _a.queries, guards = _a.guards, viewQueries = _a.viewQueries, entryComponents = _a.entryComponents, template = _a.template, componentViewType = _a.componentViewType, rendererType = _a.rendererType, componentFactory = _a.componentFactory; - var hostListeners = {}; - var hostProperties = {}; - var hostAttributes = {}; - if (host != null) { - Object.keys(host).forEach(function (key) { - var value = host[key]; - var matches = key.match(HOST_REG_EXP); - if (matches === null) { - hostAttributes[key] = value; - } - else if (matches[1] != null) { - hostProperties[matches[1]] = value; - } - else if (matches[2] != null) { - hostListeners[matches[2]] = value; - } - }); - } - var inputsMap = {}; - if (inputs != null) { - inputs.forEach(function (bindConfig) { - // canonical syntax: `dirProp: elProp` - // if there is no `:`, use dirProp = elProp - var parts = splitAtColon(bindConfig, [bindConfig, bindConfig]); - inputsMap[parts[0]] = parts[1]; - }); - } - var outputsMap = {}; - if (outputs != null) { - outputs.forEach(function (bindConfig) { - // canonical syntax: `dirProp: elProp` - // if there is no `:`, use dirProp = elProp - var parts = splitAtColon(bindConfig, [bindConfig, bindConfig]); - outputsMap[parts[0]] = parts[1]; - }); - } - return new CompileDirectiveMetadata({ - isHost: isHost, - type: type, - isComponent: !!isComponent, selector: selector, exportAs: exportAs, changeDetection: changeDetection, - inputs: inputsMap, - outputs: outputsMap, - hostListeners: hostListeners, - hostProperties: hostProperties, - hostAttributes: hostAttributes, - providers: providers, - viewProviders: viewProviders, - queries: queries, - guards: guards, - viewQueries: viewQueries, - entryComponents: entryComponents, - template: template, - componentViewType: componentViewType, - rendererType: rendererType, - componentFactory: componentFactory, - }); - }; - CompileDirectiveMetadata.prototype.toSummary = function () { - return { - summaryKind: CompileSummaryKind.Directive, - type: this.type, - isComponent: this.isComponent, - selector: this.selector, - exportAs: this.exportAs, - inputs: this.inputs, - outputs: this.outputs, - hostListeners: this.hostListeners, - hostProperties: this.hostProperties, - hostAttributes: this.hostAttributes, - providers: this.providers, - viewProviders: this.viewProviders, - queries: this.queries, - guards: this.guards, - viewQueries: this.viewQueries, - entryComponents: this.entryComponents, - changeDetection: this.changeDetection, - template: this.template && this.template.toSummary(), - componentViewType: this.componentViewType, - rendererType: this.rendererType, - componentFactory: this.componentFactory - }; - }; - return CompileDirectiveMetadata; -}()); -var CompilePipeMetadata = /** @class */ (function () { - function CompilePipeMetadata(_a) { - var type = _a.type, name = _a.name, pure = _a.pure; - this.type = type; - this.name = name; - this.pure = !!pure; - } - CompilePipeMetadata.prototype.toSummary = function () { - return { - summaryKind: CompileSummaryKind.Pipe, - type: this.type, - name: this.name, - pure: this.pure - }; - }; - return CompilePipeMetadata; -}()); -var CompileShallowModuleMetadata = /** @class */ (function () { - function CompileShallowModuleMetadata() { - } - return CompileShallowModuleMetadata; -}()); -/** - * Metadata regarding compilation of a module. - */ -var CompileNgModuleMetadata = /** @class */ (function () { - function CompileNgModuleMetadata(_a) { - var type = _a.type, providers = _a.providers, declaredDirectives = _a.declaredDirectives, exportedDirectives = _a.exportedDirectives, declaredPipes = _a.declaredPipes, exportedPipes = _a.exportedPipes, entryComponents = _a.entryComponents, bootstrapComponents = _a.bootstrapComponents, importedModules = _a.importedModules, exportedModules = _a.exportedModules, schemas = _a.schemas, transitiveModule = _a.transitiveModule, id = _a.id; - this.type = type || null; - this.declaredDirectives = _normalizeArray(declaredDirectives); - this.exportedDirectives = _normalizeArray(exportedDirectives); - this.declaredPipes = _normalizeArray(declaredPipes); - this.exportedPipes = _normalizeArray(exportedPipes); - this.providers = _normalizeArray(providers); - this.entryComponents = _normalizeArray(entryComponents); - this.bootstrapComponents = _normalizeArray(bootstrapComponents); - this.importedModules = _normalizeArray(importedModules); - this.exportedModules = _normalizeArray(exportedModules); - this.schemas = _normalizeArray(schemas); - this.id = id || null; - this.transitiveModule = transitiveModule || null; - } - CompileNgModuleMetadata.prototype.toSummary = function () { - var module = this.transitiveModule; - return { - summaryKind: CompileSummaryKind.NgModule, - type: this.type, - entryComponents: module.entryComponents, - providers: module.providers, - modules: module.modules, - exportedDirectives: module.exportedDirectives, - exportedPipes: module.exportedPipes - }; - }; - return CompileNgModuleMetadata; -}()); -var TransitiveCompileNgModuleMetadata = /** @class */ (function () { - function TransitiveCompileNgModuleMetadata() { - this.directivesSet = new Set(); - this.directives = []; - this.exportedDirectivesSet = new Set(); - this.exportedDirectives = []; - this.pipesSet = new Set(); - this.pipes = []; - this.exportedPipesSet = new Set(); - this.exportedPipes = []; - this.modulesSet = new Set(); - this.modules = []; - this.entryComponentsSet = new Set(); - this.entryComponents = []; - this.providers = []; - } - TransitiveCompileNgModuleMetadata.prototype.addProvider = function (provider, module) { - this.providers.push({ provider: provider, module: module }); - }; - TransitiveCompileNgModuleMetadata.prototype.addDirective = function (id) { - if (!this.directivesSet.has(id.reference)) { - this.directivesSet.add(id.reference); - this.directives.push(id); - } - }; - TransitiveCompileNgModuleMetadata.prototype.addExportedDirective = function (id) { - if (!this.exportedDirectivesSet.has(id.reference)) { - this.exportedDirectivesSet.add(id.reference); - this.exportedDirectives.push(id); - } - }; - TransitiveCompileNgModuleMetadata.prototype.addPipe = function (id) { - if (!this.pipesSet.has(id.reference)) { - this.pipesSet.add(id.reference); - this.pipes.push(id); - } - }; - TransitiveCompileNgModuleMetadata.prototype.addExportedPipe = function (id) { - if (!this.exportedPipesSet.has(id.reference)) { - this.exportedPipesSet.add(id.reference); - this.exportedPipes.push(id); - } - }; - TransitiveCompileNgModuleMetadata.prototype.addModule = function (id) { - if (!this.modulesSet.has(id.reference)) { - this.modulesSet.add(id.reference); - this.modules.push(id); - } - }; - TransitiveCompileNgModuleMetadata.prototype.addEntryComponent = function (ec) { - if (!this.entryComponentsSet.has(ec.componentType)) { - this.entryComponentsSet.add(ec.componentType); - this.entryComponents.push(ec); - } - }; - return TransitiveCompileNgModuleMetadata; -}()); -function _normalizeArray(obj) { - return obj || []; -} -var ProviderMeta = /** @class */ (function () { - function ProviderMeta(token, _a) { - var useClass = _a.useClass, useValue = _a.useValue, useExisting = _a.useExisting, useFactory = _a.useFactory, deps = _a.deps, multi = _a.multi; - this.token = token; - this.useClass = useClass || null; - this.useValue = useValue; - this.useExisting = useExisting; - this.useFactory = useFactory || null; - this.dependencies = deps || null; - this.multi = !!multi; - } - return ProviderMeta; -}()); -function flatten(list) { - return list.reduce(function (flat, item) { - var flatItem = Array.isArray(item) ? flatten(item) : item; - return flat.concat(flatItem); - }, []); -} -function jitSourceUrl(url) { - // Note: We need 3 "/" so that ng shows up as a separate domain - // in the chrome dev tools. - return url.replace(/(\w+:\/\/[\w:-]+)?(\/+)?/, 'ng:///'); -} -function templateSourceUrl(ngModuleType, compMeta, templateMeta) { - var url; - if (templateMeta.isInline) { - if (compMeta.type.reference instanceof StaticSymbol) { - // Note: a .ts file might contain multiple components with inline templates, - // so we need to give them unique urls, as these will be used for sourcemaps. - url = compMeta.type.reference.filePath + "." + compMeta.type.reference.name + ".html"; - } - else { - url = identifierName(ngModuleType) + "/" + identifierName(compMeta.type) + ".html"; - } - } - else { - url = templateMeta.templateUrl; - } - return compMeta.type.reference instanceof StaticSymbol ? url : jitSourceUrl(url); -} -function sharedStylesheetJitUrl(meta, id) { - var pathParts = meta.moduleUrl.split(/\/\\/g); - var baseName = pathParts[pathParts.length - 1]; - return jitSourceUrl("css/" + id + baseName + ".ngstyle.js"); -} -function ngModuleJitUrl(moduleMeta) { - return jitSourceUrl(identifierName(moduleMeta.type) + "/module.ngfactory.js"); -} -function templateJitUrl(ngModuleType, compMeta) { - return jitSourceUrl(identifierName(ngModuleType) + "/" + identifierName(compMeta.type) + ".ngfactory.js"); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var CORE$1 = '@angular/core'; -var Identifiers$1 = /** @class */ (function () { - function Identifiers() { - } - /* Methods */ - Identifiers.NEW_METHOD = 'factory'; - Identifiers.TRANSFORM_METHOD = 'transform'; - Identifiers.PATCH_DEPS = 'patchedDeps'; - /* Instructions */ - Identifiers.namespaceHTML = { name: 'ɵɵnamespaceHTML', moduleName: CORE$1 }; - Identifiers.namespaceMathML = { name: 'ɵɵnamespaceMathML', moduleName: CORE$1 }; - Identifiers.namespaceSVG = { name: 'ɵɵnamespaceSVG', moduleName: CORE$1 }; - Identifiers.element = { name: 'ɵɵelement', moduleName: CORE$1 }; - Identifiers.elementStart = { name: 'ɵɵelementStart', moduleName: CORE$1 }; - Identifiers.elementEnd = { name: 'ɵɵelementEnd', moduleName: CORE$1 }; - Identifiers.select = { name: 'ɵɵselect', moduleName: CORE$1 }; - Identifiers.updateSyntheticHostBinding = { name: 'ɵɵupdateSyntheticHostBinding', moduleName: CORE$1 }; - Identifiers.componentHostSyntheticListener = { name: 'ɵɵcomponentHostSyntheticListener', moduleName: CORE$1 }; - Identifiers.attribute = { name: 'ɵɵattribute', moduleName: CORE$1 }; - Identifiers.attributeInterpolate1 = { name: 'ɵɵattributeInterpolate1', moduleName: CORE$1 }; - Identifiers.attributeInterpolate2 = { name: 'ɵɵattributeInterpolate2', moduleName: CORE$1 }; - Identifiers.attributeInterpolate3 = { name: 'ɵɵattributeInterpolate3', moduleName: CORE$1 }; - Identifiers.attributeInterpolate4 = { name: 'ɵɵattributeInterpolate4', moduleName: CORE$1 }; - Identifiers.attributeInterpolate5 = { name: 'ɵɵattributeInterpolate5', moduleName: CORE$1 }; - Identifiers.attributeInterpolate6 = { name: 'ɵɵattributeInterpolate6', moduleName: CORE$1 }; - Identifiers.attributeInterpolate7 = { name: 'ɵɵattributeInterpolate7', moduleName: CORE$1 }; - Identifiers.attributeInterpolate8 = { name: 'ɵɵattributeInterpolate8', moduleName: CORE$1 }; - Identifiers.attributeInterpolateV = { name: 'ɵɵattributeInterpolateV', moduleName: CORE$1 }; - Identifiers.classProp = { name: 'ɵɵclassProp', moduleName: CORE$1 }; - Identifiers.elementContainerStart = { name: 'ɵɵelementContainerStart', moduleName: CORE$1 }; - Identifiers.elementContainerEnd = { name: 'ɵɵelementContainerEnd', moduleName: CORE$1 }; - Identifiers.elementContainer = { name: 'ɵɵelementContainer', moduleName: CORE$1 }; - Identifiers.styling = { name: 'ɵɵstyling', moduleName: CORE$1 }; - Identifiers.styleMap = { name: 'ɵɵstyleMap', moduleName: CORE$1 }; - Identifiers.classMap = { name: 'ɵɵclassMap', moduleName: CORE$1 }; - Identifiers.classMapInterpolate1 = { name: 'ɵɵclassMapInterpolate1', moduleName: CORE$1 }; - Identifiers.classMapInterpolate2 = { name: 'ɵɵclassMapInterpolate2', moduleName: CORE$1 }; - Identifiers.classMapInterpolate3 = { name: 'ɵɵclassMapInterpolate3', moduleName: CORE$1 }; - Identifiers.classMapInterpolate4 = { name: 'ɵɵclassMapInterpolate4', moduleName: CORE$1 }; - Identifiers.classMapInterpolate5 = { name: 'ɵɵclassMapInterpolate5', moduleName: CORE$1 }; - Identifiers.classMapInterpolate6 = { name: 'ɵɵclassMapInterpolate6', moduleName: CORE$1 }; - Identifiers.classMapInterpolate7 = { name: 'ɵɵclassMapInterpolate7', moduleName: CORE$1 }; - Identifiers.classMapInterpolate8 = { name: 'ɵɵclassMapInterpolate8', moduleName: CORE$1 }; - Identifiers.classMapInterpolateV = { name: 'ɵɵclassMapInterpolateV', moduleName: CORE$1 }; - Identifiers.styleProp = { name: 'ɵɵstyleProp', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate1 = { name: 'ɵɵstylePropInterpolate1', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate2 = { name: 'ɵɵstylePropInterpolate2', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate3 = { name: 'ɵɵstylePropInterpolate3', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate4 = { name: 'ɵɵstylePropInterpolate4', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate5 = { name: 'ɵɵstylePropInterpolate5', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate6 = { name: 'ɵɵstylePropInterpolate6', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate7 = { name: 'ɵɵstylePropInterpolate7', moduleName: CORE$1 }; - Identifiers.stylePropInterpolate8 = { name: 'ɵɵstylePropInterpolate8', moduleName: CORE$1 }; - Identifiers.stylePropInterpolateV = { name: 'ɵɵstylePropInterpolateV', moduleName: CORE$1 }; - Identifiers.stylingApply = { name: 'ɵɵstylingApply', moduleName: CORE$1 }; - Identifiers.styleSanitizer = { name: 'ɵɵstyleSanitizer', moduleName: CORE$1 }; - Identifiers.elementHostAttrs = { name: 'ɵɵelementHostAttrs', moduleName: CORE$1 }; - Identifiers.containerCreate = { name: 'ɵɵcontainer', moduleName: CORE$1 }; - Identifiers.nextContext = { name: 'ɵɵnextContext', moduleName: CORE$1 }; - Identifiers.templateCreate = { name: 'ɵɵtemplate', moduleName: CORE$1 }; - Identifiers.text = { name: 'ɵɵtext', moduleName: CORE$1 }; - Identifiers.textBinding = { name: 'ɵɵtextBinding', moduleName: CORE$1 }; - Identifiers.enableBindings = { name: 'ɵɵenableBindings', moduleName: CORE$1 }; - Identifiers.disableBindings = { name: 'ɵɵdisableBindings', moduleName: CORE$1 }; - Identifiers.allocHostVars = { name: 'ɵɵallocHostVars', moduleName: CORE$1 }; - Identifiers.getCurrentView = { name: 'ɵɵgetCurrentView', moduleName: CORE$1 }; - Identifiers.textInterpolate = { name: 'ɵɵtextInterpolate', moduleName: CORE$1 }; - Identifiers.textInterpolate1 = { name: 'ɵɵtextInterpolate1', moduleName: CORE$1 }; - Identifiers.textInterpolate2 = { name: 'ɵɵtextInterpolate2', moduleName: CORE$1 }; - Identifiers.textInterpolate3 = { name: 'ɵɵtextInterpolate3', moduleName: CORE$1 }; - Identifiers.textInterpolate4 = { name: 'ɵɵtextInterpolate4', moduleName: CORE$1 }; - Identifiers.textInterpolate5 = { name: 'ɵɵtextInterpolate5', moduleName: CORE$1 }; - Identifiers.textInterpolate6 = { name: 'ɵɵtextInterpolate6', moduleName: CORE$1 }; - Identifiers.textInterpolate7 = { name: 'ɵɵtextInterpolate7', moduleName: CORE$1 }; - Identifiers.textInterpolate8 = { name: 'ɵɵtextInterpolate8', moduleName: CORE$1 }; - Identifiers.textInterpolateV = { name: 'ɵɵtextInterpolateV', moduleName: CORE$1 }; - Identifiers.restoreView = { name: 'ɵɵrestoreView', moduleName: CORE$1 }; - Identifiers.pureFunction0 = { name: 'ɵɵpureFunction0', moduleName: CORE$1 }; - Identifiers.pureFunction1 = { name: 'ɵɵpureFunction1', moduleName: CORE$1 }; - Identifiers.pureFunction2 = { name: 'ɵɵpureFunction2', moduleName: CORE$1 }; - Identifiers.pureFunction3 = { name: 'ɵɵpureFunction3', moduleName: CORE$1 }; - Identifiers.pureFunction4 = { name: 'ɵɵpureFunction4', moduleName: CORE$1 }; - Identifiers.pureFunction5 = { name: 'ɵɵpureFunction5', moduleName: CORE$1 }; - Identifiers.pureFunction6 = { name: 'ɵɵpureFunction6', moduleName: CORE$1 }; - Identifiers.pureFunction7 = { name: 'ɵɵpureFunction7', moduleName: CORE$1 }; - Identifiers.pureFunction8 = { name: 'ɵɵpureFunction8', moduleName: CORE$1 }; - Identifiers.pureFunctionV = { name: 'ɵɵpureFunctionV', moduleName: CORE$1 }; - Identifiers.pipeBind1 = { name: 'ɵɵpipeBind1', moduleName: CORE$1 }; - Identifiers.pipeBind2 = { name: 'ɵɵpipeBind2', moduleName: CORE$1 }; - Identifiers.pipeBind3 = { name: 'ɵɵpipeBind3', moduleName: CORE$1 }; - Identifiers.pipeBind4 = { name: 'ɵɵpipeBind4', moduleName: CORE$1 }; - Identifiers.pipeBindV = { name: 'ɵɵpipeBindV', moduleName: CORE$1 }; - Identifiers.hostProperty = { name: 'ɵɵhostProperty', moduleName: CORE$1 }; - Identifiers.property = { name: 'ɵɵproperty', moduleName: CORE$1 }; - Identifiers.propertyInterpolate = { name: 'ɵɵpropertyInterpolate', moduleName: CORE$1 }; - Identifiers.propertyInterpolate1 = { name: 'ɵɵpropertyInterpolate1', moduleName: CORE$1 }; - Identifiers.propertyInterpolate2 = { name: 'ɵɵpropertyInterpolate2', moduleName: CORE$1 }; - Identifiers.propertyInterpolate3 = { name: 'ɵɵpropertyInterpolate3', moduleName: CORE$1 }; - Identifiers.propertyInterpolate4 = { name: 'ɵɵpropertyInterpolate4', moduleName: CORE$1 }; - Identifiers.propertyInterpolate5 = { name: 'ɵɵpropertyInterpolate5', moduleName: CORE$1 }; - Identifiers.propertyInterpolate6 = { name: 'ɵɵpropertyInterpolate6', moduleName: CORE$1 }; - Identifiers.propertyInterpolate7 = { name: 'ɵɵpropertyInterpolate7', moduleName: CORE$1 }; - Identifiers.propertyInterpolate8 = { name: 'ɵɵpropertyInterpolate8', moduleName: CORE$1 }; - Identifiers.propertyInterpolateV = { name: 'ɵɵpropertyInterpolateV', moduleName: CORE$1 }; - Identifiers.i18n = { name: 'ɵɵi18n', moduleName: CORE$1 }; - Identifiers.i18nAttributes = { name: 'ɵɵi18nAttributes', moduleName: CORE$1 }; - Identifiers.i18nExp = { name: 'ɵɵi18nExp', moduleName: CORE$1 }; - Identifiers.i18nStart = { name: 'ɵɵi18nStart', moduleName: CORE$1 }; - Identifiers.i18nEnd = { name: 'ɵɵi18nEnd', moduleName: CORE$1 }; - Identifiers.i18nApply = { name: 'ɵɵi18nApply', moduleName: CORE$1 }; - Identifiers.i18nPostprocess = { name: 'ɵɵi18nPostprocess', moduleName: CORE$1 }; - Identifiers.i18nLocalize = { name: 'ɵɵi18nLocalize', moduleName: CORE$1 }; - Identifiers.load = { name: 'ɵɵload', moduleName: CORE$1 }; - Identifiers.pipe = { name: 'ɵɵpipe', moduleName: CORE$1 }; - Identifiers.projection = { name: 'ɵɵprojection', moduleName: CORE$1 }; - Identifiers.projectionDef = { name: 'ɵɵprojectionDef', moduleName: CORE$1 }; - Identifiers.reference = { name: 'ɵɵreference', moduleName: CORE$1 }; - Identifiers.inject = { name: 'ɵɵinject', moduleName: CORE$1 }; - Identifiers.injectAttribute = { name: 'ɵɵinjectAttribute', moduleName: CORE$1 }; - Identifiers.injectPipeChangeDetectorRef = { name: 'ɵɵinjectPipeChangeDetectorRef', moduleName: CORE$1 }; - Identifiers.directiveInject = { name: 'ɵɵdirectiveInject', moduleName: CORE$1 }; - Identifiers.templateRefExtractor = { name: 'ɵɵtemplateRefExtractor', moduleName: CORE$1 }; - Identifiers.resolveWindow = { name: 'ɵɵresolveWindow', moduleName: CORE$1 }; - Identifiers.resolveDocument = { name: 'ɵɵresolveDocument', moduleName: CORE$1 }; - Identifiers.resolveBody = { name: 'ɵɵresolveBody', moduleName: CORE$1 }; - Identifiers.defineBase = { name: 'ɵɵdefineBase', moduleName: CORE$1 }; - Identifiers.BaseDef = { - name: 'ɵɵBaseDef', - moduleName: CORE$1, - }; - Identifiers.defineComponent = { name: 'ɵɵdefineComponent', moduleName: CORE$1 }; - Identifiers.setComponentScope = { name: 'ɵɵsetComponentScope', moduleName: CORE$1 }; - Identifiers.ComponentDefWithMeta = { - name: 'ɵɵComponentDefWithMeta', - moduleName: CORE$1, - }; - Identifiers.defineDirective = { - name: 'ɵɵdefineDirective', - moduleName: CORE$1, - }; - Identifiers.DirectiveDefWithMeta = { - name: 'ɵɵDirectiveDefWithMeta', - moduleName: CORE$1, - }; - Identifiers.InjectorDef = { - name: 'ɵɵInjectorDef', - moduleName: CORE$1, - }; - Identifiers.defineInjector = { - name: 'ɵɵdefineInjector', - moduleName: CORE$1, - }; - Identifiers.NgModuleDefWithMeta = { - name: 'ɵɵNgModuleDefWithMeta', - moduleName: CORE$1, - }; - Identifiers.defineNgModule = { name: 'ɵɵdefineNgModule', moduleName: CORE$1 }; - Identifiers.setNgModuleScope = { name: 'ɵɵsetNgModuleScope', moduleName: CORE$1 }; - Identifiers.PipeDefWithMeta = { name: 'ɵɵPipeDefWithMeta', moduleName: CORE$1 }; - Identifiers.definePipe = { name: 'ɵɵdefinePipe', moduleName: CORE$1 }; - Identifiers.queryRefresh = { name: 'ɵɵqueryRefresh', moduleName: CORE$1 }; - Identifiers.viewQuery = { name: 'ɵɵviewQuery', moduleName: CORE$1 }; - Identifiers.staticViewQuery = { name: 'ɵɵstaticViewQuery', moduleName: CORE$1 }; - Identifiers.staticContentQuery = { name: 'ɵɵstaticContentQuery', moduleName: CORE$1 }; - Identifiers.loadViewQuery = { name: 'ɵɵloadViewQuery', moduleName: CORE$1 }; - Identifiers.contentQuery = { name: 'ɵɵcontentQuery', moduleName: CORE$1 }; - Identifiers.loadContentQuery = { name: 'ɵɵloadContentQuery', moduleName: CORE$1 }; - Identifiers.NgOnChangesFeature = { name: 'ɵɵNgOnChangesFeature', moduleName: CORE$1 }; - Identifiers.InheritDefinitionFeature = { name: 'ɵɵInheritDefinitionFeature', moduleName: CORE$1 }; - Identifiers.ProvidersFeature = { name: 'ɵɵProvidersFeature', moduleName: CORE$1 }; - Identifiers.listener = { name: 'ɵɵlistener', moduleName: CORE$1 }; - Identifiers.getFactoryOf = { - name: 'ɵɵgetFactoryOf', - moduleName: CORE$1, - }; - Identifiers.getInheritedFactory = { - name: 'ɵɵgetInheritedFactory', - moduleName: CORE$1, - }; - // sanitization-related functions - Identifiers.sanitizeHtml = { name: 'ɵɵsanitizeHtml', moduleName: CORE$1 }; - Identifiers.sanitizeStyle = { name: 'ɵɵsanitizeStyle', moduleName: CORE$1 }; - Identifiers.defaultStyleSanitizer = { name: 'ɵɵdefaultStyleSanitizer', moduleName: CORE$1 }; - Identifiers.sanitizeResourceUrl = { name: 'ɵɵsanitizeResourceUrl', moduleName: CORE$1 }; - Identifiers.sanitizeScript = { name: 'ɵɵsanitizeScript', moduleName: CORE$1 }; - Identifiers.sanitizeUrl = { name: 'ɵɵsanitizeUrl', moduleName: CORE$1 }; - Identifiers.sanitizeUrlOrResourceUrl = { name: 'ɵɵsanitizeUrlOrResourceUrl', moduleName: CORE$1 }; - return Identifiers; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var $EOF = 0; -var $BSPACE = 8; -var $TAB = 9; -var $LF = 10; -var $VTAB = 11; -var $FF = 12; -var $CR = 13; -var $SPACE = 32; -var $BANG = 33; -var $DQ = 34; -var $HASH = 35; -var $$ = 36; -var $PERCENT = 37; -var $AMPERSAND = 38; -var $SQ = 39; -var $LPAREN = 40; -var $RPAREN = 41; -var $STAR = 42; -var $PLUS = 43; -var $COMMA = 44; -var $MINUS = 45; -var $PERIOD = 46; -var $SLASH = 47; -var $COLON = 58; -var $SEMICOLON = 59; -var $LT = 60; -var $EQ = 61; -var $GT = 62; -var $QUESTION = 63; -var $0 = 48; -var $7 = 55; -var $9 = 57; -var $A = 65; -var $E = 69; -var $F = 70; -var $X = 88; -var $Z = 90; -var $LBRACKET = 91; -var $BACKSLASH = 92; -var $RBRACKET = 93; -var $CARET = 94; -var $_ = 95; -var $a = 97; -var $b = 98; -var $e = 101; -var $f = 102; -var $n = 110; -var $r = 114; -var $t = 116; -var $u = 117; -var $v = 118; -var $x = 120; -var $z = 122; -var $LBRACE = 123; -var $BAR = 124; -var $RBRACE = 125; -var $NBSP = 160; -var $PIPE = 124; -var $TILDA = 126; -var $AT = 64; -var $BT = 96; -function isWhitespace(code) { - return (code >= $TAB && code <= $SPACE) || (code == $NBSP); -} -function isDigit(code) { - return $0 <= code && code <= $9; -} -function isAsciiLetter(code) { - return code >= $a && code <= $z || code >= $A && code <= $Z; -} -function isAsciiHexDigit(code) { - return code >= $a && code <= $f || code >= $A && code <= $F || isDigit(code); -} -function isNewLine(code) { - return code === $LF || code === $CR; -} -function isOctalDigit(code) { - return $0 <= code && code <= $7; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var ParseLocation = /** @class */ (function () { - function ParseLocation(file, offset, line, col) { - this.file = file; - this.offset = offset; - this.line = line; - this.col = col; - } - ParseLocation.prototype.toString = function () { - return this.offset != null ? this.file.url + "@" + this.line + ":" + this.col : this.file.url; - }; - ParseLocation.prototype.moveBy = function (delta) { - var source = this.file.content; - var len = source.length; - var offset = this.offset; - var line = this.line; - var col = this.col; - while (offset > 0 && delta < 0) { - offset--; - delta++; - var ch = source.charCodeAt(offset); - if (ch == $LF) { - line--; - var priorLine = source.substr(0, offset - 1).lastIndexOf(String.fromCharCode($LF)); - col = priorLine > 0 ? offset - priorLine : offset; - } - else { - col--; - } - } - while (offset < len && delta > 0) { - var ch = source.charCodeAt(offset); - offset++; - delta--; - if (ch == $LF) { - line++; - col = 0; - } - else { - col++; - } - } - return new ParseLocation(this.file, offset, line, col); - }; - // Return the source around the location - // Up to `maxChars` or `maxLines` on each side of the location - ParseLocation.prototype.getContext = function (maxChars, maxLines) { - var content = this.file.content; - var startOffset = this.offset; - if (startOffset != null) { - if (startOffset > content.length - 1) { - startOffset = content.length - 1; - } - var endOffset = startOffset; - var ctxChars = 0; - var ctxLines = 0; - while (ctxChars < maxChars && startOffset > 0) { - startOffset--; - ctxChars++; - if (content[startOffset] == '\n') { - if (++ctxLines == maxLines) { - break; - } - } - } - ctxChars = 0; - ctxLines = 0; - while (ctxChars < maxChars && endOffset < content.length - 1) { - endOffset++; - ctxChars++; - if (content[endOffset] == '\n') { - if (++ctxLines == maxLines) { - break; - } - } - } - return { - before: content.substring(startOffset, this.offset), - after: content.substring(this.offset, endOffset + 1), - }; - } - return null; - }; - return ParseLocation; -}()); -var ParseSourceFile = /** @class */ (function () { - function ParseSourceFile(content, url) { - this.content = content; - this.url = url; - } - return ParseSourceFile; -}()); -var ParseSourceSpan = /** @class */ (function () { - function ParseSourceSpan(start, end, details) { - if (details === void 0) { details = null; } - this.start = start; - this.end = end; - this.details = details; - } - ParseSourceSpan.prototype.toString = function () { - return this.start.file.content.substring(this.start.offset, this.end.offset); - }; - return ParseSourceSpan; -}()); -var EMPTY_PARSE_LOCATION = new ParseLocation(new ParseSourceFile('', ''), 0, 0, 0); -var EMPTY_SOURCE_SPAN = new ParseSourceSpan(EMPTY_PARSE_LOCATION, EMPTY_PARSE_LOCATION); -var ParseErrorLevel; -(function (ParseErrorLevel) { - ParseErrorLevel[ParseErrorLevel["WARNING"] = 0] = "WARNING"; - ParseErrorLevel[ParseErrorLevel["ERROR"] = 1] = "ERROR"; -})(ParseErrorLevel || (ParseErrorLevel = {})); -var ParseError = /** @class */ (function () { - function ParseError(span, msg, level) { - if (level === void 0) { level = ParseErrorLevel.ERROR; } - this.span = span; - this.msg = msg; - this.level = level; - } - ParseError.prototype.contextualMessage = function () { - var ctx = this.span.start.getContext(100, 3); - return ctx ? this.msg + " (\"" + ctx.before + "[" + ParseErrorLevel[this.level] + " ->]" + ctx.after + "\")" : - this.msg; - }; - ParseError.prototype.toString = function () { - var details = this.span.details ? ", " + this.span.details : ''; - return this.contextualMessage() + ": " + this.span.start + details; - }; - return ParseError; -}()); -function typeSourceSpan(kind, type) { - var moduleUrl = identifierModuleUrl(type); - var sourceFileName = moduleUrl != null ? "in " + kind + " " + identifierName(type) + " in " + moduleUrl : - "in " + kind + " " + identifierName(type); - var sourceFile = new ParseSourceFile('', sourceFileName); - return new ParseSourceSpan(new ParseLocation(sourceFile, -1, -1, -1), new ParseLocation(sourceFile, -1, -1, -1)); -} -/** - * Generates Source Span object for a given R3 Type for JIT mode. - * - * @param kind Component or Directive. - * @param typeName name of the Component or Directive. - * @param sourceUrl reference to Component or Directive source. - * @returns instance of ParseSourceSpan that represent a given Component or Directive. - */ -function r3JitTypeSourceSpan(kind, typeName, sourceUrl) { - var sourceFileName = "in " + kind + " " + typeName + " in " + sourceUrl; - var sourceFile = new ParseSourceFile('', sourceFileName); - return new ParseSourceSpan(new ParseLocation(sourceFile, -1, -1, -1), new ParseLocation(sourceFile, -1, -1, -1)); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var Text = /** @class */ (function () { - function Text(value, sourceSpan) { - this.value = value; - this.sourceSpan = sourceSpan; - } - Text.prototype.visit = function (visitor) { return visitor.visitText(this); }; - return Text; -}()); -var BoundText = /** @class */ (function () { - function BoundText(value, sourceSpan, i18n) { - this.value = value; - this.sourceSpan = sourceSpan; - this.i18n = i18n; - } - BoundText.prototype.visit = function (visitor) { return visitor.visitBoundText(this); }; - return BoundText; -}()); -var TextAttribute = /** @class */ (function () { - function TextAttribute(name, value, sourceSpan, valueSpan, i18n) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - this.i18n = i18n; - } - TextAttribute.prototype.visit = function (visitor) { return visitor.visitTextAttribute(this); }; - return TextAttribute; -}()); -var BoundAttribute = /** @class */ (function () { - function BoundAttribute(name, type, securityContext, value, unit, sourceSpan, valueSpan, i18n) { - this.name = name; - this.type = type; - this.securityContext = securityContext; - this.value = value; - this.unit = unit; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - this.i18n = i18n; - } - BoundAttribute.fromBoundElementProperty = function (prop, i18n) { - return new BoundAttribute(prop.name, prop.type, prop.securityContext, prop.value, prop.unit, prop.sourceSpan, prop.valueSpan, i18n); - }; - BoundAttribute.prototype.visit = function (visitor) { return visitor.visitBoundAttribute(this); }; - return BoundAttribute; -}()); -var BoundEvent = /** @class */ (function () { - function BoundEvent(name, type, handler, target, phase, sourceSpan, handlerSpan) { - this.name = name; - this.type = type; - this.handler = handler; - this.target = target; - this.phase = phase; - this.sourceSpan = sourceSpan; - this.handlerSpan = handlerSpan; - } - BoundEvent.fromParsedEvent = function (event) { - var target = event.type === 0 /* Regular */ ? event.targetOrPhase : null; - var phase = event.type === 1 /* Animation */ ? event.targetOrPhase : null; - return new BoundEvent(event.name, event.type, event.handler, target, phase, event.sourceSpan, event.handlerSpan); - }; - BoundEvent.prototype.visit = function (visitor) { return visitor.visitBoundEvent(this); }; - return BoundEvent; -}()); -var Element = /** @class */ (function () { - function Element(name, attributes, inputs, outputs, children, references, sourceSpan, startSourceSpan, endSourceSpan, i18n) { - this.name = name; - this.attributes = attributes; - this.inputs = inputs; - this.outputs = outputs; - this.children = children; - this.references = references; - this.sourceSpan = sourceSpan; - this.startSourceSpan = startSourceSpan; - this.endSourceSpan = endSourceSpan; - this.i18n = i18n; - // If the element is empty then the source span should include any closing tag - if (children.length === 0 && startSourceSpan && endSourceSpan) { - this.sourceSpan = new ParseSourceSpan(sourceSpan.start, endSourceSpan.end); - } - } - Element.prototype.visit = function (visitor) { return visitor.visitElement(this); }; - return Element; -}()); -var Template = /** @class */ (function () { - function Template(tagName, attributes, inputs, outputs, templateAttrs, children, references, variables, sourceSpan, startSourceSpan, endSourceSpan, i18n) { - this.tagName = tagName; - this.attributes = attributes; - this.inputs = inputs; - this.outputs = outputs; - this.templateAttrs = templateAttrs; - this.children = children; - this.references = references; - this.variables = variables; - this.sourceSpan = sourceSpan; - this.startSourceSpan = startSourceSpan; - this.endSourceSpan = endSourceSpan; - this.i18n = i18n; - } - Template.prototype.visit = function (visitor) { return visitor.visitTemplate(this); }; - return Template; -}()); -var Content = /** @class */ (function () { - function Content(selector, attributes, sourceSpan, i18n) { - this.selector = selector; - this.attributes = attributes; - this.sourceSpan = sourceSpan; - this.i18n = i18n; - } - Content.prototype.visit = function (visitor) { return visitor.visitContent(this); }; - return Content; -}()); -var Variable = /** @class */ (function () { - function Variable(name, value, sourceSpan, valueSpan) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - } - Variable.prototype.visit = function (visitor) { return visitor.visitVariable(this); }; - return Variable; -}()); -var Reference = /** @class */ (function () { - function Reference(name, value, sourceSpan, valueSpan) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - } - Reference.prototype.visit = function (visitor) { return visitor.visitReference(this); }; - return Reference; -}()); -var Icu = /** @class */ (function () { - function Icu(vars, placeholders, sourceSpan, i18n) { - this.vars = vars; - this.placeholders = placeholders; - this.sourceSpan = sourceSpan; - this.i18n = i18n; - } - Icu.prototype.visit = function (visitor) { return visitor.visitIcu(this); }; - return Icu; -}()); -var NullVisitor = /** @class */ (function () { - function NullVisitor() { - } - NullVisitor.prototype.visitElement = function (element) { }; - NullVisitor.prototype.visitTemplate = function (template) { }; - NullVisitor.prototype.visitContent = function (content) { }; - NullVisitor.prototype.visitVariable = function (variable) { }; - NullVisitor.prototype.visitReference = function (reference) { }; - NullVisitor.prototype.visitTextAttribute = function (attribute) { }; - NullVisitor.prototype.visitBoundAttribute = function (attribute) { }; - NullVisitor.prototype.visitBoundEvent = function (attribute) { }; - NullVisitor.prototype.visitText = function (text) { }; - NullVisitor.prototype.visitBoundText = function (text) { }; - NullVisitor.prototype.visitIcu = function (icu) { }; - return NullVisitor; -}()); -var RecursiveVisitor = /** @class */ (function () { - function RecursiveVisitor() { - } - RecursiveVisitor.prototype.visitElement = function (element) { - visitAll(this, element.attributes); - visitAll(this, element.children); - visitAll(this, element.references); - }; - RecursiveVisitor.prototype.visitTemplate = function (template) { - visitAll(this, template.attributes); - visitAll(this, template.children); - visitAll(this, template.references); - visitAll(this, template.variables); - }; - RecursiveVisitor.prototype.visitContent = function (content) { }; - RecursiveVisitor.prototype.visitVariable = function (variable) { }; - RecursiveVisitor.prototype.visitReference = function (reference) { }; - RecursiveVisitor.prototype.visitTextAttribute = function (attribute) { }; - RecursiveVisitor.prototype.visitBoundAttribute = function (attribute) { }; - RecursiveVisitor.prototype.visitBoundEvent = function (attribute) { }; - RecursiveVisitor.prototype.visitText = function (text) { }; - RecursiveVisitor.prototype.visitBoundText = function (text) { }; - RecursiveVisitor.prototype.visitIcu = function (icu) { }; - return RecursiveVisitor; -}()); -var TransformVisitor = /** @class */ (function () { - function TransformVisitor() { - } - TransformVisitor.prototype.visitElement = function (element) { - var newAttributes = transformAll(this, element.attributes); - var newInputs = transformAll(this, element.inputs); - var newOutputs = transformAll(this, element.outputs); - var newChildren = transformAll(this, element.children); - var newReferences = transformAll(this, element.references); - if (newAttributes != element.attributes || newInputs != element.inputs || - newOutputs != element.outputs || newChildren != element.children || - newReferences != element.references) { - return new Element(element.name, newAttributes, newInputs, newOutputs, newChildren, newReferences, element.sourceSpan, element.startSourceSpan, element.endSourceSpan); - } - return element; - }; - TransformVisitor.prototype.visitTemplate = function (template) { - var newAttributes = transformAll(this, template.attributes); - var newInputs = transformAll(this, template.inputs); - var newOutputs = transformAll(this, template.outputs); - var newTemplateAttrs = transformAll(this, template.templateAttrs); - var newChildren = transformAll(this, template.children); - var newReferences = transformAll(this, template.references); - var newVariables = transformAll(this, template.variables); - if (newAttributes != template.attributes || newInputs != template.inputs || - newOutputs != template.outputs || newTemplateAttrs != template.templateAttrs || - newChildren != template.children || newReferences != template.references || - newVariables != template.variables) { - return new Template(template.tagName, newAttributes, newInputs, newOutputs, newTemplateAttrs, newChildren, newReferences, newVariables, template.sourceSpan, template.startSourceSpan, template.endSourceSpan); - } - return template; - }; - TransformVisitor.prototype.visitContent = function (content) { return content; }; - TransformVisitor.prototype.visitVariable = function (variable) { return variable; }; - TransformVisitor.prototype.visitReference = function (reference) { return reference; }; - TransformVisitor.prototype.visitTextAttribute = function (attribute) { return attribute; }; - TransformVisitor.prototype.visitBoundAttribute = function (attribute) { return attribute; }; - TransformVisitor.prototype.visitBoundEvent = function (attribute) { return attribute; }; - TransformVisitor.prototype.visitText = function (text) { return text; }; - TransformVisitor.prototype.visitBoundText = function (text) { return text; }; - TransformVisitor.prototype.visitIcu = function (icu) { return icu; }; - return TransformVisitor; -}()); -function visitAll(visitor, nodes) { - var e_1, _a, e_2, _b; - var result = []; - if (visitor.visit) { - try { - for (var nodes_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(nodes), nodes_1_1 = nodes_1.next(); !nodes_1_1.done; nodes_1_1 = nodes_1.next()) { - var node = nodes_1_1.value; - var newNode = visitor.visit(node) || node.visit(visitor); - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (nodes_1_1 && !nodes_1_1.done && (_a = nodes_1.return)) _a.call(nodes_1); - } - finally { if (e_1) throw e_1.error; } - } - } - else { - try { - for (var nodes_2 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(nodes), nodes_2_1 = nodes_2.next(); !nodes_2_1.done; nodes_2_1 = nodes_2.next()) { - var node = nodes_2_1.value; - var newNode = node.visit(visitor); - if (newNode) { - result.push(newNode); - } - } - } - catch (e_2_1) { e_2 = { error: e_2_1 }; } - finally { - try { - if (nodes_2_1 && !nodes_2_1.done && (_b = nodes_2.return)) _b.call(nodes_2); - } - finally { if (e_2) throw e_2.error; } - } - } - return result; -} -function transformAll(visitor, nodes) { - var e_3, _a; - var result = []; - var changed = false; - try { - for (var nodes_3 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(nodes), nodes_3_1 = nodes_3.next(); !nodes_3_1.done; nodes_3_1 = nodes_3.next()) { - var node = nodes_3_1.value; - var newNode = node.visit(visitor); - if (newNode) { - result.push(newNode); - } - changed = changed || newNode != node; - } - } - catch (e_3_1) { e_3 = { error: e_3_1 }; } - finally { - try { - if (nodes_3_1 && !nodes_3_1.done && (_a = nodes_3.return)) _a.call(nodes_3); - } - finally { if (e_3) throw e_3.error; } - } - return changed ? result : nodes; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var Message = /** @class */ (function () { - /** - * @param nodes message AST - * @param placeholders maps placeholder names to static content - * @param placeholderToMessage maps placeholder names to messages (used for nested ICU messages) - * @param meaning - * @param description - * @param id - */ - function Message(nodes, placeholders, placeholderToMessage, meaning, description, id) { - this.nodes = nodes; - this.placeholders = placeholders; - this.placeholderToMessage = placeholderToMessage; - this.meaning = meaning; - this.description = description; - this.id = id; - if (nodes.length) { - this.sources = [{ - filePath: nodes[0].sourceSpan.start.file.url, - startLine: nodes[0].sourceSpan.start.line + 1, - startCol: nodes[0].sourceSpan.start.col + 1, - endLine: nodes[nodes.length - 1].sourceSpan.end.line + 1, - endCol: nodes[0].sourceSpan.start.col + 1 - }]; - } - else { - this.sources = []; - } - } - return Message; -}()); -var Text$1 = /** @class */ (function () { - function Text(value, sourceSpan) { - this.value = value; - this.sourceSpan = sourceSpan; - } - Text.prototype.visit = function (visitor, context) { return visitor.visitText(this, context); }; - return Text; -}()); -// TODO(vicb): do we really need this node (vs an array) ? -var Container = /** @class */ (function () { - function Container(children, sourceSpan) { - this.children = children; - this.sourceSpan = sourceSpan; - } - Container.prototype.visit = function (visitor, context) { return visitor.visitContainer(this, context); }; - return Container; -}()); -var Icu$1 = /** @class */ (function () { - function Icu(expression, type, cases, sourceSpan) { - this.expression = expression; - this.type = type; - this.cases = cases; - this.sourceSpan = sourceSpan; - } - Icu.prototype.visit = function (visitor, context) { return visitor.visitIcu(this, context); }; - return Icu; -}()); -var TagPlaceholder = /** @class */ (function () { - function TagPlaceholder(tag, attrs, startName, closeName, children, isVoid, sourceSpan) { - this.tag = tag; - this.attrs = attrs; - this.startName = startName; - this.closeName = closeName; - this.children = children; - this.isVoid = isVoid; - this.sourceSpan = sourceSpan; - } - TagPlaceholder.prototype.visit = function (visitor, context) { return visitor.visitTagPlaceholder(this, context); }; - return TagPlaceholder; -}()); -var Placeholder = /** @class */ (function () { - function Placeholder(value, name, sourceSpan) { - this.value = value; - this.name = name; - this.sourceSpan = sourceSpan; - } - Placeholder.prototype.visit = function (visitor, context) { return visitor.visitPlaceholder(this, context); }; - return Placeholder; -}()); -var IcuPlaceholder = /** @class */ (function () { - function IcuPlaceholder(value, name, sourceSpan) { - this.value = value; - this.name = name; - this.sourceSpan = sourceSpan; - } - IcuPlaceholder.prototype.visit = function (visitor, context) { return visitor.visitIcuPlaceholder(this, context); }; - return IcuPlaceholder; -}()); -// Clone the AST -var CloneVisitor = /** @class */ (function () { - function CloneVisitor() { - } - CloneVisitor.prototype.visitText = function (text, context) { return new Text$1(text.value, text.sourceSpan); }; - CloneVisitor.prototype.visitContainer = function (container, context) { - var _this = this; - var children = container.children.map(function (n) { return n.visit(_this, context); }); - return new Container(children, container.sourceSpan); - }; - CloneVisitor.prototype.visitIcu = function (icu, context) { - var _this = this; - var cases = {}; - Object.keys(icu.cases).forEach(function (key) { return cases[key] = icu.cases[key].visit(_this, context); }); - var msg = new Icu$1(icu.expression, icu.type, cases, icu.sourceSpan); - msg.expressionPlaceholder = icu.expressionPlaceholder; - return msg; - }; - CloneVisitor.prototype.visitTagPlaceholder = function (ph, context) { - var _this = this; - var children = ph.children.map(function (n) { return n.visit(_this, context); }); - return new TagPlaceholder(ph.tag, ph.attrs, ph.startName, ph.closeName, children, ph.isVoid, ph.sourceSpan); - }; - CloneVisitor.prototype.visitPlaceholder = function (ph, context) { - return new Placeholder(ph.value, ph.name, ph.sourceSpan); - }; - CloneVisitor.prototype.visitIcuPlaceholder = function (ph, context) { - return new IcuPlaceholder(ph.value, ph.name, ph.sourceSpan); - }; - return CloneVisitor; -}()); -// Visit all the nodes recursively -var RecurseVisitor = /** @class */ (function () { - function RecurseVisitor() { - } - RecurseVisitor.prototype.visitText = function (text, context) { }; - RecurseVisitor.prototype.visitContainer = function (container, context) { - var _this = this; - container.children.forEach(function (child) { return child.visit(_this); }); - }; - RecurseVisitor.prototype.visitIcu = function (icu, context) { - var _this = this; - Object.keys(icu.cases).forEach(function (k) { icu.cases[k].visit(_this); }); - }; - RecurseVisitor.prototype.visitTagPlaceholder = function (ph, context) { - var _this = this; - ph.children.forEach(function (child) { return child.visit(_this); }); - }; - RecurseVisitor.prototype.visitPlaceholder = function (ph, context) { }; - RecurseVisitor.prototype.visitIcuPlaceholder = function (ph, context) { }; - return RecurseVisitor; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function digest(message) { - return message.id || sha1(serializeNodes(message.nodes).join('') + ("[" + message.meaning + "]")); -} -function decimalDigest(message) { - if (message.id) { - return message.id; - } - var visitor = new _SerializerIgnoreIcuExpVisitor(); - var parts = message.nodes.map(function (a) { return a.visit(visitor, null); }); - return computeMsgId(parts.join(''), message.meaning); -} -/** - * Serialize the i18n ast to something xml-like in order to generate an UID. - * - * The visitor is also used in the i18n parser tests - * - * @internal - */ -var _SerializerVisitor = /** @class */ (function () { - function _SerializerVisitor() { - } - _SerializerVisitor.prototype.visitText = function (text, context) { return text.value; }; - _SerializerVisitor.prototype.visitContainer = function (container, context) { - var _this = this; - return "[" + container.children.map(function (child) { return child.visit(_this); }).join(', ') + "]"; - }; - _SerializerVisitor.prototype.visitIcu = function (icu, context) { - var _this = this; - var strCases = Object.keys(icu.cases).map(function (k) { return k + " {" + icu.cases[k].visit(_this) + "}"; }); - return "{" + icu.expression + ", " + icu.type + ", " + strCases.join(', ') + "}"; - }; - _SerializerVisitor.prototype.visitTagPlaceholder = function (ph, context) { - var _this = this; - return ph.isVoid ? - "" : - "" + ph.children.map(function (child) { return child.visit(_this); }).join(', ') + ""; - }; - _SerializerVisitor.prototype.visitPlaceholder = function (ph, context) { - return ph.value ? "" + ph.value + "" : ""; - }; - _SerializerVisitor.prototype.visitIcuPlaceholder = function (ph, context) { - return "" + ph.value.visit(this) + ""; - }; - return _SerializerVisitor; -}()); -var serializerVisitor = new _SerializerVisitor(); -function serializeNodes(nodes) { - return nodes.map(function (a) { return a.visit(serializerVisitor, null); }); -} -/** - * Serialize the i18n ast to something xml-like in order to generate an UID. - * - * Ignore the ICU expressions so that message IDs stays identical if only the expression changes. - * - * @internal - */ -var _SerializerIgnoreIcuExpVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(_SerializerIgnoreIcuExpVisitor, _super); - function _SerializerIgnoreIcuExpVisitor() { - return _super !== null && _super.apply(this, arguments) || this; - } - _SerializerIgnoreIcuExpVisitor.prototype.visitIcu = function (icu, context) { - var _this = this; - var strCases = Object.keys(icu.cases).map(function (k) { return k + " {" + icu.cases[k].visit(_this) + "}"; }); - // Do not take the expression into account - return "{" + icu.type + ", " + strCases.join(', ') + "}"; - }; - return _SerializerIgnoreIcuExpVisitor; -}(_SerializerVisitor)); -/** - * Compute the SHA1 of the given string - * - * see http://csrc.nist.gov/publications/fips/fips180-4/fips-180-4.pdf - * - * WARNING: this function has not been designed not tested with security in mind. - * DO NOT USE IT IN A SECURITY SENSITIVE CONTEXT. - */ -function sha1(str) { - var _a, _b; - var utf8 = utf8Encode(str); - var words32 = stringToWords32(utf8, Endian.Big); - var len = utf8.length * 8; - var w = new Array(80); - var _c = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476, 0xc3d2e1f0], 5), a = _c[0], b = _c[1], c = _c[2], d = _c[3], e = _c[4]; - words32[len >> 5] |= 0x80 << (24 - len % 32); - words32[((len + 64 >> 9) << 4) + 15] = len; - for (var i = 0; i < words32.length; i += 16) { - var _d = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([a, b, c, d, e], 5), h0 = _d[0], h1 = _d[1], h2 = _d[2], h3 = _d[3], h4 = _d[4]; - for (var j = 0; j < 80; j++) { - if (j < 16) { - w[j] = words32[i + j]; - } - else { - w[j] = rol32(w[j - 3] ^ w[j - 8] ^ w[j - 14] ^ w[j - 16], 1); - } - var _e = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(fk(j, b, c, d), 2), f = _e[0], k = _e[1]; - var temp = [rol32(a, 5), f, e, k, w[j]].reduce(add32); - _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([d, c, rol32(b, 30), a, temp], 5), e = _a[0], d = _a[1], c = _a[2], b = _a[3], a = _a[4]; - } - _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([add32(a, h0), add32(b, h1), add32(c, h2), add32(d, h3), add32(e, h4)], 5), a = _b[0], b = _b[1], c = _b[2], d = _b[3], e = _b[4]; - } - return byteStringToHexString(words32ToByteString([a, b, c, d, e])); -} -function fk(index, b, c, d) { - if (index < 20) { - return [(b & c) | (~b & d), 0x5a827999]; - } - if (index < 40) { - return [b ^ c ^ d, 0x6ed9eba1]; - } - if (index < 60) { - return [(b & c) | (b & d) | (c & d), 0x8f1bbcdc]; - } - return [b ^ c ^ d, 0xca62c1d6]; -} -/** - * Compute the fingerprint of the given string - * - * The output is 64 bit number encoded as a decimal string - * - * based on: - * https://github.com/google/closure-compiler/blob/master/src/com/google/javascript/jscomp/GoogleJsMessageIdGenerator.java - */ -function fingerprint(str) { - var utf8 = utf8Encode(str); - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([hash32(utf8, 0), hash32(utf8, 102072)], 2), hi = _a[0], lo = _a[1]; - if (hi == 0 && (lo == 0 || lo == 1)) { - hi = hi ^ 0x130f9bef; - lo = lo ^ -0x6b5f56d8; - } - return [hi, lo]; -} -function computeMsgId(msg, meaning) { - var _a; - var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(fingerprint(msg), 2), hi = _b[0], lo = _b[1]; - if (meaning) { - var _c = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(fingerprint(meaning), 2), him = _c[0], lom = _c[1]; - _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(add64(rol64([hi, lo], 1), [him, lom]), 2), hi = _a[0], lo = _a[1]; - } - return byteStringToDecString(words32ToByteString([hi & 0x7fffffff, lo])); -} -function hash32(str, c) { - var _a; - var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])([0x9e3779b9, 0x9e3779b9], 2), a = _b[0], b = _b[1]; - var i; - var len = str.length; - for (i = 0; i + 12 <= len; i += 12) { - a = add32(a, wordAt(str, i, Endian.Little)); - b = add32(b, wordAt(str, i + 4, Endian.Little)); - c = add32(c, wordAt(str, i + 8, Endian.Little)); - _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(mix([a, b, c]), 3), a = _a[0], b = _a[1], c = _a[2]; - } - a = add32(a, wordAt(str, i, Endian.Little)); - b = add32(b, wordAt(str, i + 4, Endian.Little)); - // the first byte of c is reserved for the length - c = add32(c, len); - c = add32(c, wordAt(str, i + 8, Endian.Little) << 8); - return mix([a, b, c])[2]; -} -// clang-format off -function mix(_a) { - var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(_a, 3), a = _b[0], b = _b[1], c = _b[2]; - a = sub32(a, b); - a = sub32(a, c); - a ^= c >>> 13; - b = sub32(b, c); - b = sub32(b, a); - b ^= a << 8; - c = sub32(c, a); - c = sub32(c, b); - c ^= b >>> 13; - a = sub32(a, b); - a = sub32(a, c); - a ^= c >>> 12; - b = sub32(b, c); - b = sub32(b, a); - b ^= a << 16; - c = sub32(c, a); - c = sub32(c, b); - c ^= b >>> 5; - a = sub32(a, b); - a = sub32(a, c); - a ^= c >>> 3; - b = sub32(b, c); - b = sub32(b, a); - b ^= a << 10; - c = sub32(c, a); - c = sub32(c, b); - c ^= b >>> 15; - return [a, b, c]; -} -// clang-format on -// Utils -var Endian; -(function (Endian) { - Endian[Endian["Little"] = 0] = "Little"; - Endian[Endian["Big"] = 1] = "Big"; -})(Endian || (Endian = {})); -function add32(a, b) { - return add32to64(a, b)[1]; -} -function add32to64(a, b) { - var low = (a & 0xffff) + (b & 0xffff); - var high = (a >>> 16) + (b >>> 16) + (low >>> 16); - return [high >>> 16, (high << 16) | (low & 0xffff)]; -} -function add64(_a, _b) { - var _c = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(_a, 2), ah = _c[0], al = _c[1]; - var _d = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(_b, 2), bh = _d[0], bl = _d[1]; - var _e = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(add32to64(al, bl), 2), carry = _e[0], l = _e[1]; - var h = add32(add32(ah, bh), carry); - return [h, l]; -} -function sub32(a, b) { - var low = (a & 0xffff) - (b & 0xffff); - var high = (a >> 16) - (b >> 16) + (low >> 16); - return (high << 16) | (low & 0xffff); -} -// Rotate a 32b number left `count` position -function rol32(a, count) { - return (a << count) | (a >>> (32 - count)); -} -// Rotate a 64b number left `count` position -function rol64(_a, count) { - var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(_a, 2), hi = _b[0], lo = _b[1]; - var h = (hi << count) | (lo >>> (32 - count)); - var l = (lo << count) | (hi >>> (32 - count)); - return [h, l]; -} -function stringToWords32(str, endian) { - var words32 = Array((str.length + 3) >>> 2); - for (var i = 0; i < words32.length; i++) { - words32[i] = wordAt(str, i * 4, endian); - } - return words32; -} -function byteAt(str, index) { - return index >= str.length ? 0 : str.charCodeAt(index) & 0xff; -} -function wordAt(str, index, endian) { - var word = 0; - if (endian === Endian.Big) { - for (var i = 0; i < 4; i++) { - word += byteAt(str, index + i) << (24 - 8 * i); - } - } - else { - for (var i = 0; i < 4; i++) { - word += byteAt(str, index + i) << 8 * i; - } - } - return word; -} -function words32ToByteString(words32) { - return words32.reduce(function (str, word) { return str + word32ToByteString(word); }, ''); -} -function word32ToByteString(word) { - var str = ''; - for (var i = 0; i < 4; i++) { - str += String.fromCharCode((word >>> 8 * (3 - i)) & 0xff); - } - return str; -} -function byteStringToHexString(str) { - var hex = ''; - for (var i = 0; i < str.length; i++) { - var b = byteAt(str, i); - hex += (b >>> 4).toString(16) + (b & 0x0f).toString(16); - } - return hex.toLowerCase(); -} -// based on http://www.danvk.org/hex2dec.html (JS can not handle more than 56b) -function byteStringToDecString(str) { - var decimal = ''; - var toThePower = '1'; - for (var i = str.length - 1; i >= 0; i--) { - decimal = addBigInt(decimal, numberTimesBigInt(byteAt(str, i), toThePower)); - toThePower = numberTimesBigInt(256, toThePower); - } - return decimal.split('').reverse().join(''); -} -// x and y decimal, lowest significant digit first -function addBigInt(x, y) { - var sum = ''; - var len = Math.max(x.length, y.length); - for (var i = 0, carry = 0; i < len || carry; i++) { - var tmpSum = carry + +(x[i] || 0) + +(y[i] || 0); - if (tmpSum >= 10) { - carry = 1; - sum += tmpSum - 10; - } - else { - carry = 0; - sum += tmpSum; - } - } - return sum; -} -function numberTimesBigInt(num, b) { - var product = ''; - var bToThePower = b; - for (; num !== 0; num = num >>> 1) { - if (num & 1) - product = addBigInt(product, bToThePower); - bToThePower = addBigInt(bToThePower, bToThePower); - } - return product; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var Serializer = /** @class */ (function () { - function Serializer() { - } - // Creates a name mapper, see `PlaceholderMapper` - // Returning `null` means that no name mapping is used. - Serializer.prototype.createNameMapper = function (message) { return null; }; - return Serializer; -}()); -/** - * A simple mapper that take a function to transform an internal name to a public name - */ -var SimplePlaceholderMapper = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(SimplePlaceholderMapper, _super); - // create a mapping from the message - function SimplePlaceholderMapper(message, mapName) { - var _this = _super.call(this) || this; - _this.mapName = mapName; - _this.internalToPublic = {}; - _this.publicToNextId = {}; - _this.publicToInternal = {}; - message.nodes.forEach(function (node) { return node.visit(_this); }); - return _this; - } - SimplePlaceholderMapper.prototype.toPublicName = function (internalName) { - return this.internalToPublic.hasOwnProperty(internalName) ? - this.internalToPublic[internalName] : - null; - }; - SimplePlaceholderMapper.prototype.toInternalName = function (publicName) { - return this.publicToInternal.hasOwnProperty(publicName) ? this.publicToInternal[publicName] : - null; - }; - SimplePlaceholderMapper.prototype.visitText = function (text, context) { return null; }; - SimplePlaceholderMapper.prototype.visitTagPlaceholder = function (ph, context) { - this.visitPlaceholderName(ph.startName); - _super.prototype.visitTagPlaceholder.call(this, ph, context); - this.visitPlaceholderName(ph.closeName); - }; - SimplePlaceholderMapper.prototype.visitPlaceholder = function (ph, context) { this.visitPlaceholderName(ph.name); }; - SimplePlaceholderMapper.prototype.visitIcuPlaceholder = function (ph, context) { - this.visitPlaceholderName(ph.name); - }; - // XMB placeholders could only contains A-Z, 0-9 and _ - SimplePlaceholderMapper.prototype.visitPlaceholderName = function (internalName) { - if (!internalName || this.internalToPublic.hasOwnProperty(internalName)) { - return; - } - var publicName = this.mapName(internalName); - if (this.publicToInternal.hasOwnProperty(publicName)) { - // Create a new XMB when it has already been used - var nextId = this.publicToNextId[publicName]; - this.publicToNextId[publicName] = nextId + 1; - publicName = publicName + "_" + nextId; - } - else { - this.publicToNextId[publicName] = 1; - } - this.internalToPublic[internalName] = publicName; - this.publicToInternal[publicName] = internalName; - }; - return SimplePlaceholderMapper; -}(RecurseVisitor)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _Visitor = /** @class */ (function () { - function _Visitor() { - } - _Visitor.prototype.visitTag = function (tag) { - var _this = this; - var strAttrs = this._serializeAttributes(tag.attrs); - if (tag.children.length == 0) { - return "<" + tag.name + strAttrs + "/>"; - } - var strChildren = tag.children.map(function (node) { return node.visit(_this); }); - return "<" + tag.name + strAttrs + ">" + strChildren.join('') + ""; - }; - _Visitor.prototype.visitText = function (text) { return text.value; }; - _Visitor.prototype.visitDeclaration = function (decl) { - return ""; - }; - _Visitor.prototype._serializeAttributes = function (attrs) { - var strAttrs = Object.keys(attrs).map(function (name) { return name + "=\"" + attrs[name] + "\""; }).join(' '); - return strAttrs.length > 0 ? ' ' + strAttrs : ''; - }; - _Visitor.prototype.visitDoctype = function (doctype) { - return ""; - }; - return _Visitor; -}()); -var _visitor = new _Visitor(); -function serialize(nodes) { - return nodes.map(function (node) { return node.visit(_visitor); }).join(''); -} -var Declaration = /** @class */ (function () { - function Declaration(unescapedAttrs) { - var _this = this; - this.attrs = {}; - Object.keys(unescapedAttrs).forEach(function (k) { - _this.attrs[k] = escapeXml(unescapedAttrs[k]); - }); - } - Declaration.prototype.visit = function (visitor) { return visitor.visitDeclaration(this); }; - return Declaration; -}()); -var Doctype = /** @class */ (function () { - function Doctype(rootTag, dtd) { - this.rootTag = rootTag; - this.dtd = dtd; - } - Doctype.prototype.visit = function (visitor) { return visitor.visitDoctype(this); }; - return Doctype; -}()); -var Tag = /** @class */ (function () { - function Tag(name, unescapedAttrs, children) { - var _this = this; - if (unescapedAttrs === void 0) { unescapedAttrs = {}; } - if (children === void 0) { children = []; } - this.name = name; - this.children = children; - this.attrs = {}; - Object.keys(unescapedAttrs).forEach(function (k) { - _this.attrs[k] = escapeXml(unescapedAttrs[k]); - }); - } - Tag.prototype.visit = function (visitor) { return visitor.visitTag(this); }; - return Tag; -}()); -var Text$2 = /** @class */ (function () { - function Text(unescapedValue) { - this.value = escapeXml(unescapedValue); - } - Text.prototype.visit = function (visitor) { return visitor.visitText(this); }; - return Text; -}()); -var CR = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(CR, _super); - function CR(ws) { - if (ws === void 0) { ws = 0; } - return _super.call(this, "\n" + new Array(ws + 1).join(' ')) || this; - } - return CR; -}(Text$2)); -var _ESCAPED_CHARS = [ - [/&/g, '&'], - [/"/g, '"'], - [/'/g, '''], - [//g, '>'], -]; -// Escape `_ESCAPED_CHARS` characters in the given text with encoded entities -function escapeXml(text) { - return _ESCAPED_CHARS.reduce(function (text, entry) { return text.replace(entry[0], entry[1]); }, text); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _MESSAGES_TAG = 'messagebundle'; -var _MESSAGE_TAG = 'msg'; -var _PLACEHOLDER_TAG = 'ph'; -var _EXAMPLE_TAG = 'ex'; -var _SOURCE_TAG = 'source'; -var _DOCTYPE = "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"; -var Xmb = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Xmb, _super); - function Xmb() { - return _super !== null && _super.apply(this, arguments) || this; - } - Xmb.prototype.write = function (messages, locale) { - var exampleVisitor = new ExampleVisitor(); - var visitor = new _Visitor$1(); - var rootNode = new Tag(_MESSAGES_TAG); - messages.forEach(function (message) { - var attrs = { id: message.id }; - if (message.description) { - attrs['desc'] = message.description; - } - if (message.meaning) { - attrs['meaning'] = message.meaning; - } - var sourceTags = []; - message.sources.forEach(function (source) { - sourceTags.push(new Tag(_SOURCE_TAG, {}, [ - new Text$2(source.filePath + ":" + source.startLine + (source.endLine !== source.startLine ? ',' + source.endLine : '')) - ])); - }); - rootNode.children.push(new CR(2), new Tag(_MESSAGE_TAG, attrs, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(sourceTags, visitor.serialize(message.nodes)))); - }); - rootNode.children.push(new CR()); - return serialize([ - new Declaration({ version: '1.0', encoding: 'UTF-8' }), - new CR(), - new Doctype(_MESSAGES_TAG, _DOCTYPE), - new CR(), - exampleVisitor.addDefaultExamples(rootNode), - new CR(), - ]); - }; - Xmb.prototype.load = function (content, url) { - throw new Error('Unsupported'); - }; - Xmb.prototype.digest = function (message) { return digest$1(message); }; - Xmb.prototype.createNameMapper = function (message) { - return new SimplePlaceholderMapper(message, toPublicName); - }; - return Xmb; -}(Serializer)); -var _Visitor$1 = /** @class */ (function () { - function _Visitor() { - } - _Visitor.prototype.visitText = function (text, context) { return [new Text$2(text.value)]; }; - _Visitor.prototype.visitContainer = function (container, context) { - var _this = this; - var nodes = []; - container.children.forEach(function (node) { return nodes.push.apply(nodes, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(node.visit(_this))); }); - return nodes; - }; - _Visitor.prototype.visitIcu = function (icu, context) { - var _this = this; - var nodes = [new Text$2("{" + icu.expressionPlaceholder + ", " + icu.type + ", ")]; - Object.keys(icu.cases).forEach(function (c) { - nodes.push.apply(nodes, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([new Text$2(c + " {")], icu.cases[c].visit(_this), [new Text$2("} ")])); - }); - nodes.push(new Text$2("}")); - return nodes; - }; - _Visitor.prototype.visitTagPlaceholder = function (ph, context) { - var startTagAsText = new Text$2("<" + ph.tag + ">"); - var startEx = new Tag(_EXAMPLE_TAG, {}, [startTagAsText]); - // TC requires PH to have a non empty EX, and uses the text node to show the "original" value. - var startTagPh = new Tag(_PLACEHOLDER_TAG, { name: ph.startName }, [startEx, startTagAsText]); - if (ph.isVoid) { - // void tags have no children nor closing tags - return [startTagPh]; - } - var closeTagAsText = new Text$2(""); - var closeEx = new Tag(_EXAMPLE_TAG, {}, [closeTagAsText]); - // TC requires PH to have a non empty EX, and uses the text node to show the "original" value. - var closeTagPh = new Tag(_PLACEHOLDER_TAG, { name: ph.closeName }, [closeEx, closeTagAsText]); - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([startTagPh], this.serialize(ph.children), [closeTagPh]); - }; - _Visitor.prototype.visitPlaceholder = function (ph, context) { - var interpolationAsText = new Text$2("{{" + ph.value + "}}"); - // Example tag needs to be not-empty for TC. - var exTag = new Tag(_EXAMPLE_TAG, {}, [interpolationAsText]); - return [ - // TC requires PH to have a non empty EX, and uses the text node to show the "original" value. - new Tag(_PLACEHOLDER_TAG, { name: ph.name }, [exTag, interpolationAsText]) - ]; - }; - _Visitor.prototype.visitIcuPlaceholder = function (ph, context) { - var icuExpression = ph.value.expression; - var icuType = ph.value.type; - var icuCases = Object.keys(ph.value.cases).map(function (value) { return value + ' {...}'; }).join(' '); - var icuAsText = new Text$2("{" + icuExpression + ", " + icuType + ", " + icuCases + "}"); - var exTag = new Tag(_EXAMPLE_TAG, {}, [icuAsText]); - return [ - // TC requires PH to have a non empty EX, and uses the text node to show the "original" value. - new Tag(_PLACEHOLDER_TAG, { name: ph.name }, [exTag, icuAsText]) - ]; - }; - _Visitor.prototype.serialize = function (nodes) { - var _this = this; - return [].concat.apply([], Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(nodes.map(function (node) { return node.visit(_this); }))); - }; - return _Visitor; -}()); -function digest$1(message) { - return decimalDigest(message); -} -// TC requires at least one non-empty example on placeholders -var ExampleVisitor = /** @class */ (function () { - function ExampleVisitor() { - } - ExampleVisitor.prototype.addDefaultExamples = function (node) { - node.visit(this); - return node; - }; - ExampleVisitor.prototype.visitTag = function (tag) { - var _this = this; - if (tag.name === _PLACEHOLDER_TAG) { - if (!tag.children || tag.children.length == 0) { - var exText = new Text$2(tag.attrs['name'] || '...'); - tag.children = [new Tag(_EXAMPLE_TAG, {}, [exText])]; - } - } - else if (tag.children) { - tag.children.forEach(function (node) { return node.visit(_this); }); - } - }; - ExampleVisitor.prototype.visitText = function (text) { }; - ExampleVisitor.prototype.visitDeclaration = function (decl) { }; - ExampleVisitor.prototype.visitDoctype = function (doctype) { }; - return ExampleVisitor; -}()); -// XMB/XTB placeholders can only contain A-Z, 0-9 and _ -function toPublicName(internalName) { - return internalName.toUpperCase().replace(/[^A-Z0-9_]/g, '_'); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function mapEntry(key, value) { - return { key: key, value: value, quoted: false }; -} -function mapLiteral(obj, quoted) { - if (quoted === void 0) { quoted = false; } - return literalMap(Object.keys(obj).map(function (key) { return ({ - key: key, - quoted: quoted, - value: obj[key], - }); })); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/* Closure variables holding messages must be named `MSG_[A-Z0-9]+` */ -var CLOSURE_TRANSLATION_PREFIX = 'MSG_'; -/* Prefix for non-`goog.getMsg` i18n-related vars */ -var TRANSLATION_PREFIX = 'I18N_'; -/** Closure uses `goog.getMsg(message)` to lookup translations */ -var GOOG_GET_MSG = 'goog.getMsg'; -/** Name of the global variable that is used to determine if we use Closure translations or not */ -var NG_I18N_CLOSURE_MODE = 'ngI18nClosureMode'; -/** I18n separators for metadata **/ -var I18N_MEANING_SEPARATOR = '|'; -var I18N_ID_SEPARATOR = '@@'; -/** Name of the i18n attributes **/ -var I18N_ATTR = 'i18n'; -var I18N_ATTR_PREFIX = 'i18n-'; -/** Prefix of var expressions used in ICUs */ -var I18N_ICU_VAR_PREFIX = 'VAR_'; -/** Prefix of ICU expressions for post processing */ -var I18N_ICU_MAPPING_PREFIX = 'I18N_EXP_'; -/** Placeholder wrapper for i18n expressions **/ -var I18N_PLACEHOLDER_SYMBOL = '�'; -function i18nTranslationToDeclStmt(variable$1, closureVar, message, meta, params) { - var statements = []; - // var I18N_X; - statements.push(new DeclareVarStmt(variable$1.name, undefined, INFERRED_TYPE, null, variable$1.sourceSpan)); - var args = [literal(message)]; - if (params && Object.keys(params).length) { - args.push(mapLiteral(params, true)); - } - // Closure JSDoc comments - var docStatements = i18nMetaToDocStmt(meta); - var thenStatements = docStatements ? [docStatements] : []; - var googFnCall = variable(GOOG_GET_MSG).callFn(args); - // const MSG_... = goog.getMsg(..); - thenStatements.push(closureVar.set(googFnCall).toConstDecl()); - // I18N_X = MSG_...; - thenStatements.push(new ExpressionStatement(variable$1.set(closureVar))); - var localizeFnCall = importExpr(Identifiers$1.i18nLocalize).callFn(args); - // I18N_X = i18nLocalize(...); - var elseStatements = [new ExpressionStatement(variable$1.set(localizeFnCall))]; - // if(ngI18nClosureMode) { ... } else { ... } - statements.push(ifStmt(variable(NG_I18N_CLOSURE_MODE), thenStatements, elseStatements)); - return statements; -} -// Converts i18n meta information for a message (id, description, meaning) -// to a JsDoc statement formatted as expected by the Closure compiler. -function i18nMetaToDocStmt(meta) { - var tags = []; - if (meta.description) { - tags.push({ tagName: "desc" /* Desc */, text: meta.description }); - } - if (meta.meaning) { - tags.push({ tagName: "meaning" /* Meaning */, text: meta.meaning }); - } - return tags.length == 0 ? null : new JSDocCommentStmt(tags); -} -function isI18nAttribute(name) { - return name === I18N_ATTR || name.startsWith(I18N_ATTR_PREFIX); -} -function isI18nRootNode(meta) { - return meta instanceof Message; -} -function isSingleI18nIcu(meta) { - return isI18nRootNode(meta) && meta.nodes.length === 1 && meta.nodes[0] instanceof Icu$1; -} -function hasI18nAttrs(element) { - return element.attrs.some(function (attr) { return isI18nAttribute(attr.name); }); -} -function metaFromI18nMessage(message, id) { - if (id === void 0) { id = null; } - return { - id: typeof id === 'string' ? id : message.id || '', - meaning: message.meaning || '', - description: message.description || '' - }; -} -function icuFromI18nMessage(message) { - return message.nodes[0]; -} -function wrapI18nPlaceholder(content, contextId) { - if (contextId === void 0) { contextId = 0; } - var blockId = contextId > 0 ? ":" + contextId : ''; - return "" + I18N_PLACEHOLDER_SYMBOL + content + blockId + I18N_PLACEHOLDER_SYMBOL; -} -function assembleI18nBoundString(strings, bindingStartIndex, contextId) { - if (bindingStartIndex === void 0) { bindingStartIndex = 0; } - if (contextId === void 0) { contextId = 0; } - if (!strings.length) - return ''; - var acc = ''; - var lastIdx = strings.length - 1; - for (var i = 0; i < lastIdx; i++) { - acc += "" + strings[i] + wrapI18nPlaceholder(bindingStartIndex + i, contextId); - } - acc += strings[lastIdx]; - return acc; -} -function getSeqNumberGenerator(startsAt) { - if (startsAt === void 0) { startsAt = 0; } - var current = startsAt; - return function () { return current++; }; -} -function placeholdersToParams(placeholders) { - var params = {}; - placeholders.forEach(function (values, key) { - params[key] = literal(values.length > 1 ? "[" + values.join('|') + "]" : values[0]); - }); - return params; -} -function updatePlaceholderMap(map, name) { - var values = []; - for (var _i = 2; _i < arguments.length; _i++) { - values[_i - 2] = arguments[_i]; - } - var current = map.get(name) || []; - current.push.apply(current, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(values)); - map.set(name, current); -} -function assembleBoundTextPlaceholders(meta, bindingStartIndex, contextId) { - if (bindingStartIndex === void 0) { bindingStartIndex = 0; } - if (contextId === void 0) { contextId = 0; } - var startIdx = bindingStartIndex; - var placeholders = new Map(); - var node = meta instanceof Message ? meta.nodes.find(function (node) { return node instanceof Container; }) : meta; - if (node) { - node - .children - .filter(function (child) { return child instanceof Placeholder; }) - .forEach(function (child, idx) { - var content = wrapI18nPlaceholder(startIdx + idx, contextId); - updatePlaceholderMap(placeholders, child.name, content); - }); - } - return placeholders; -} -function findIndex(items, callback) { - for (var i = 0; i < items.length; i++) { - if (callback(items[i])) { - return i; - } - } - return -1; -} -/** - * Parses i18n metas like: - * - "@@id", - * - "description[@@id]", - * - "meaning|description[@@id]" - * and returns an object with parsed output. - * - * @param meta String that represents i18n meta - * @returns Object with id, meaning and description fields - */ -function parseI18nMeta(meta) { - var _a, _b; - var id; - var meaning; - var description; - if (meta) { - var idIndex = meta.indexOf(I18N_ID_SEPARATOR); - var descIndex = meta.indexOf(I18N_MEANING_SEPARATOR); - var meaningAndDesc = void 0; - _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])((idIndex > -1) ? [meta.slice(0, idIndex), meta.slice(idIndex + 2)] : [meta, ''], 2), meaningAndDesc = _a[0], id = _a[1]; - _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])((descIndex > -1) ? - [meaningAndDesc.slice(0, descIndex), meaningAndDesc.slice(descIndex + 1)] : - ['', meaningAndDesc], 2), meaning = _b[0], description = _b[1]; - } - return { id: id, meaning: meaning, description: description }; -} -/** - * Converts internal placeholder names to public-facing format - * (for example to use in goog.getMsg call). - * Example: `START_TAG_DIV_1` is converted to `startTagDiv_1`. - * - * @param name The placeholder name that should be formatted - * @returns Formatted placeholder name - */ -function formatI18nPlaceholderName(name, useCamelCase) { - if (useCamelCase === void 0) { useCamelCase = true; } - var publicName = toPublicName(name); - if (!useCamelCase) { - return publicName; - } - var chunks = publicName.split('_'); - if (chunks.length === 1) { - // if no "_" found - just lowercase the value - return name.toLowerCase(); - } - var postfix; - // eject last element if it's a number - if (/^\d+$/.test(chunks[chunks.length - 1])) { - postfix = chunks.pop(); - } - var raw = chunks.shift().toLowerCase(); - if (chunks.length) { - raw += chunks.map(function (c) { return c.charAt(0).toUpperCase() + c.slice(1).toLowerCase(); }).join(''); - } - return postfix ? raw + "_" + postfix : raw; -} -/** - * Generates a prefix for translation const name. - * - * @param extra Additional local prefix that should be injected into translation var name - * @returns Complete translation const prefix - */ -function getTranslationConstPrefix(extra) { - return ("" + CLOSURE_TRANSLATION_PREFIX + extra).toUpperCase(); -} -/** - * Generates translation declaration statements. - * - * @param variable Translation value reference - * @param closureVar Variable for Closure `goog.getMsg` calls - * @param message Text message to be translated - * @param meta Object that contains meta information (id, meaning and description) - * @param params Object with placeholders key-value pairs - * @param transformFn Optional transformation (post processing) function reference - * @returns Array of Statements that represent a given translation - */ -function getTranslationDeclStmts(variable, closureVar, message, meta, params, transformFn) { - if (params === void 0) { params = {}; } - var statements = []; - statements.push.apply(statements, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(i18nTranslationToDeclStmt(variable, closureVar, message, meta, params))); - if (transformFn) { - statements.push(new ExpressionStatement(variable.set(transformFn(variable)))); - } - return statements; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Checks whether an object key contains potentially unsafe chars, thus the key should be wrapped in - * quotes. Note: we do not wrap all keys into quotes, as it may have impact on minification and may - * bot work in some cases when object keys are mangled by minifier. - * - * TODO(FW-1136): this is a temporary solution, we need to come up with a better way of working with - * inputs that contain potentially unsafe chars. - */ -var UNSAFE_OBJECT_KEY_NAME_REGEXP = /[-.]/; -/** Name of the temporary to use during data binding */ -var TEMPORARY_NAME = '_t'; -/** Name of the context parameter passed into a template function */ -var CONTEXT_NAME = 'ctx'; -/** Name of the RenderFlag passed into a template function */ -var RENDER_FLAGS = 'rf'; -/** The prefix reference variables */ -var REFERENCE_PREFIX = '_r'; -/** The name of the implicit context reference */ -var IMPLICIT_REFERENCE = '$implicit'; -/** Non bindable attribute name **/ -var NON_BINDABLE_ATTR = 'ngNonBindable'; -/** - * Creates an allocator for a temporary variable. - * - * A variable declaration is added to the statements the first time the allocator is invoked. - */ -function temporaryAllocator(statements, name) { - var temp = null; - return function () { - if (!temp) { - statements.push(new DeclareVarStmt(TEMPORARY_NAME, undefined, DYNAMIC_TYPE)); - temp = variable(name); - } - return temp; - }; -} -function unsupported(feature) { - if (this) { - throw new Error("Builder " + this.constructor.name + " doesn't support " + feature + " yet"); - } - throw new Error("Feature " + feature + " is not supported yet"); -} -function invalid$1(arg) { - throw new Error("Invalid state: Visitor " + this.constructor.name + " doesn't handle " + arg.constructor.name); -} -function asLiteral(value) { - if (Array.isArray(value)) { - return literalArr(value.map(asLiteral)); - } - return literal(value, INFERRED_TYPE); -} -function conditionallyCreateMapObjectLiteral(keys, keepDeclared) { - if (Object.getOwnPropertyNames(keys).length > 0) { - return mapToExpression(keys, keepDeclared); - } - return null; -} -function mapToExpression(map, keepDeclared) { - return literalMap(Object.getOwnPropertyNames(map).map(function (key) { - var _a, _b; - // canonical syntax: `dirProp: publicProp` - // if there is no `:`, use dirProp = elProp - var value = map[key]; - var declaredName; - var publicName; - var minifiedName; - if (Array.isArray(value)) { - _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(value, 2), publicName = _a[0], declaredName = _a[1]; - } - else { - _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(splitAtColon(key, [key, value]), 2), declaredName = _b[0], publicName = _b[1]; - } - minifiedName = declaredName; - return { - key: minifiedName, - // put quotes around keys that contain potentially unsafe characters - quoted: UNSAFE_OBJECT_KEY_NAME_REGEXP.test(minifiedName), - value: (keepDeclared && publicName !== declaredName) ? - literalArr([asLiteral(publicName), asLiteral(declaredName)]) : - asLiteral(publicName) - }; - })); -} -/** - * Remove trailing null nodes as they are implied. - */ -function trimTrailingNulls(parameters) { - while (isNull(parameters[parameters.length - 1])) { - parameters.pop(); - } - return parameters; -} -function getQueryPredicate(query, constantPool) { - if (Array.isArray(query.predicate)) { - var predicate_1 = []; - query.predicate.forEach(function (selector) { - // Each item in predicates array may contain strings with comma-separated refs - // (for ex. 'ref, ref1, ..., refN'), thus we extract individual refs and store them - // as separate array entities - var selectors = selector.split(',').map(function (token) { return literal(token.trim()); }); - predicate_1.push.apply(predicate_1, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(selectors)); - }); - return constantPool.getConstLiteral(literalArr(predicate_1), true); - } - else { - return query.predicate; - } -} -function noop() { } -var DefinitionMap = /** @class */ (function () { - function DefinitionMap() { - this.values = []; - } - DefinitionMap.prototype.set = function (key, value) { - if (value) { - this.values.push({ key: key, value: value, quoted: false }); - } - }; - DefinitionMap.prototype.toLiteralMap = function () { return literalMap(this.values); }; - return DefinitionMap; -}()); -/** - * Extract a map of properties to values for a given element or template node, which can be used - * by the directive matching machinery. - * - * @param elOrTpl the element or template in question - * @return an object set up for directive matching. For attributes on the element/template, this - * object maps a property name to its (static) value. For any bindings, this map simply maps the - * property name to an empty string. - */ -function getAttrsForDirectiveMatching(elOrTpl) { - var attributesMap = {}; - if (elOrTpl instanceof Template && elOrTpl.tagName !== 'ng-template') { - elOrTpl.templateAttrs.forEach(function (a) { return attributesMap[a.name] = ''; }); - } - else { - elOrTpl.attributes.forEach(function (a) { - if (!isI18nAttribute(a.name)) { - attributesMap[a.name] = a.value; - } - }); - elOrTpl.inputs.forEach(function (i) { attributesMap[i.name] = ''; }); - elOrTpl.outputs.forEach(function (o) { attributesMap[o.name] = ''; }); - } - return attributesMap; -} -/** Returns a call expression to a chained instruction, e.g. `property(params[0])(params[1])`. */ -function chainedInstruction(reference, calls, span) { - var expression = importExpr(reference, null, span); - if (calls.length > 0) { - for (var i = 0; i < calls.length; i++) { - expression = expression.callFn(calls[i], span); - } - } - else { - // Add a blank invocation, in case the `calls` array is empty. - expression = expression.callFn([], span); - } - return expression; -} -/** - * Gets the number of arguments expected to be passed to a generated instruction in the case of - * interpolation instructions. - * @param interpolation An interpolation ast - */ -function getInterpolationArgsLength(interpolation) { - var expressions = interpolation.expressions, strings = interpolation.strings; - if (expressions.length === 1 && strings.length === 2 && strings[0] === '' && strings[1] === '') { - // If the interpolation has one interpolated value, but the prefix and suffix are both empty - // strings, we only pass one argument, to a special instruction like `propertyInterpolate` or - // `textInterpolate`. - return 1; - } - else { - return expressions.length + strings.length; - } -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var R3FactoryDelegateType; -(function (R3FactoryDelegateType) { - R3FactoryDelegateType[R3FactoryDelegateType["Class"] = 0] = "Class"; - R3FactoryDelegateType[R3FactoryDelegateType["Function"] = 1] = "Function"; - R3FactoryDelegateType[R3FactoryDelegateType["Factory"] = 2] = "Factory"; -})(R3FactoryDelegateType || (R3FactoryDelegateType = {})); -/** - * Resolved type of a dependency. - * - * Occasionally, dependencies will have special significance which is known statically. In that - * case the `R3ResolvedDependencyType` informs the factory generator that a particular dependency - * should be generated specially (usually by calling a special injection function instead of the - * standard one). - */ -var R3ResolvedDependencyType; -(function (R3ResolvedDependencyType) { - /** - * A normal token dependency. - */ - R3ResolvedDependencyType[R3ResolvedDependencyType["Token"] = 0] = "Token"; - /** - * The dependency is for an attribute. - * - * The token expression is a string representing the attribute name. - */ - R3ResolvedDependencyType[R3ResolvedDependencyType["Attribute"] = 1] = "Attribute"; - /** - * Injecting the `ChangeDetectorRef` token. Needs special handling when injected into a pipe. - */ - R3ResolvedDependencyType[R3ResolvedDependencyType["ChangeDetectorRef"] = 2] = "ChangeDetectorRef"; -})(R3ResolvedDependencyType || (R3ResolvedDependencyType = {})); -/** - * Construct a factory function expression for the given `R3FactoryMetadata`. - */ -function compileFactoryFunction(meta, isPipe) { - if (isPipe === void 0) { isPipe = false; } - var t = variable('t'); - var statements = []; - // The type to instantiate via constructor invocation. If there is no delegated factory, meaning - // this type is always created by constructor invocation, then this is the type-to-create - // parameter provided by the user (t) if specified, or the current type if not. If there is a - // delegated factory (which is used to create the current type) then this is only the type-to- - // create parameter (t). - var typeForCtor = !isDelegatedMetadata(meta) ? new BinaryOperatorExpr(BinaryOperator.Or, t, meta.type) : t; - var ctorExpr = null; - if (meta.deps !== null) { - // There is a constructor (either explicitly or implicitly defined). - if (meta.deps !== 'invalid') { - ctorExpr = - new InstantiateExpr(typeForCtor, injectDependencies(meta.deps, meta.injectFn, isPipe)); - } - } - else { - var baseFactory = variable("\u0275" + meta.name + "_BaseFactory"); - var getInheritedFactory = importExpr(Identifiers$1.getInheritedFactory); - var baseFactoryStmt = baseFactory.set(getInheritedFactory.callFn([meta.type])).toDeclStmt(INFERRED_TYPE, [ - StmtModifier.Exported, StmtModifier.Final - ]); - statements.push(baseFactoryStmt); - // There is no constructor, use the base class' factory to construct typeForCtor. - ctorExpr = baseFactory.callFn([typeForCtor]); - } - var ctorExprFinal = ctorExpr; - var body = []; - var retExpr = null; - function makeConditionalFactory(nonCtorExpr) { - var r = variable('r'); - body.push(r.set(NULL_EXPR).toDeclStmt()); - var ctorStmt = null; - if (ctorExprFinal !== null) { - ctorStmt = r.set(ctorExprFinal).toStmt(); - } - else { - ctorStmt = makeErrorStmt(meta.name); - } - body.push(ifStmt(t, [ctorStmt], [r.set(nonCtorExpr).toStmt()])); - return r; - } - if (isDelegatedMetadata(meta) && meta.delegateType === R3FactoryDelegateType.Factory) { - var delegateFactory = variable("\u0275" + meta.name + "_BaseFactory"); - var getFactoryOf = importExpr(Identifiers$1.getFactoryOf); - if (meta.delegate.isEquivalent(meta.type)) { - throw new Error("Illegal state: compiling factory that delegates to itself"); - } - var delegateFactoryStmt = delegateFactory.set(getFactoryOf.callFn([meta.delegate])).toDeclStmt(INFERRED_TYPE, [ - StmtModifier.Exported, StmtModifier.Final - ]); - statements.push(delegateFactoryStmt); - retExpr = makeConditionalFactory(delegateFactory.callFn([])); - } - else if (isDelegatedMetadata(meta)) { - // This type is created with a delegated factory. If a type parameter is not specified, call - // the factory instead. - var delegateArgs = injectDependencies(meta.delegateDeps, meta.injectFn, isPipe); - // Either call `new delegate(...)` or `delegate(...)` depending on meta.useNewForDelegate. - var factoryExpr = new (meta.delegateType === R3FactoryDelegateType.Class ? - InstantiateExpr : - InvokeFunctionExpr)(meta.delegate, delegateArgs); - retExpr = makeConditionalFactory(factoryExpr); - } - else if (isExpressionFactoryMetadata(meta)) { - // TODO(alxhub): decide whether to lower the value here or in the caller - retExpr = makeConditionalFactory(meta.expression); - } - else { - retExpr = ctorExpr; - } - if (retExpr !== null) { - body.push(new ReturnStatement(retExpr)); - } - else { - body.push(makeErrorStmt(meta.name)); - } - return { - factory: fn([new FnParam('t', DYNAMIC_TYPE)], body, INFERRED_TYPE, undefined, meta.name + "_Factory"), - statements: statements, - }; -} -function injectDependencies(deps, injectFn, isPipe) { - return deps.map(function (dep) { return compileInjectDependency(dep, injectFn, isPipe); }); -} -function compileInjectDependency(dep, injectFn, isPipe) { - // Interpret the dependency according to its resolved type. - switch (dep.resolved) { - case R3ResolvedDependencyType.Token: - case R3ResolvedDependencyType.ChangeDetectorRef: - // Build up the injection flags according to the metadata. - var flags = 0 /* Default */ | (dep.self ? 2 /* Self */ : 0) | - (dep.skipSelf ? 4 /* SkipSelf */ : 0) | (dep.host ? 1 /* Host */ : 0) | - (dep.optional ? 8 /* Optional */ : 0); - // If this dependency is optional or otherwise has non-default flags, then additional - // parameters describing how to inject the dependency must be passed to the inject function - // that's being used. - var flagsParam = (flags !== 0 /* Default */ || dep.optional) ? literal(flags) : null; - // We have a separate instruction for injecting ChangeDetectorRef into a pipe. - if (isPipe && dep.resolved === R3ResolvedDependencyType.ChangeDetectorRef) { - return importExpr(Identifiers$1.injectPipeChangeDetectorRef).callFn(flagsParam ? [flagsParam] : []); - } - // Build up the arguments to the injectFn call. - var injectArgs = [dep.token]; - if (flagsParam) { - injectArgs.push(flagsParam); - } - return importExpr(injectFn).callFn(injectArgs); - case R3ResolvedDependencyType.Attribute: - // In the case of attributes, the attribute name in question is given as the token. - return importExpr(Identifiers$1.injectAttribute).callFn([dep.token]); - default: - return unsupported("Unknown R3ResolvedDependencyType: " + R3ResolvedDependencyType[dep.resolved]); - } -} -/** - * A helper function useful for extracting `R3DependencyMetadata` from a Render2 - * `CompileTypeMetadata` instance. - */ -function dependenciesFromGlobalMetadata(type, outputCtx, reflector) { - var e_1, _a; - // Use the `CompileReflector` to look up references to some well-known Angular types. These will - // be compared with the token to statically determine whether the token has significance to - // Angular, and set the correct `R3ResolvedDependencyType` as a result. - var injectorRef = reflector.resolveExternalReference(Identifiers.Injector); - // Iterate through the type's DI dependencies and produce `R3DependencyMetadata` for each of them. - var deps = []; - try { - for (var _b = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(type.diDeps), _c = _b.next(); !_c.done; _c = _b.next()) { - var dependency = _c.value; - if (dependency.token) { - var tokenRef = tokenReference(dependency.token); - var resolved = dependency.isAttribute ? - R3ResolvedDependencyType.Attribute : - R3ResolvedDependencyType.Token; - // In the case of most dependencies, the token will be a reference to a type. Sometimes, - // however, it can be a string, in the case of older Angular code or @Attribute injection. - var token = tokenRef instanceof StaticSymbol ? outputCtx.importExpr(tokenRef) : literal(tokenRef); - // Construct the dependency. - deps.push({ - token: token, - resolved: resolved, - host: !!dependency.isHost, - optional: !!dependency.isOptional, - self: !!dependency.isSelf, - skipSelf: !!dependency.isSkipSelf, - }); - } - else { - unsupported('dependency without a token'); - } - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (_c && !_c.done && (_a = _b.return)) _a.call(_b); - } - finally { if (e_1) throw e_1.error; } - } - return deps; -} -function makeErrorStmt(name) { - return new ThrowStmt(new InstantiateExpr(new ReadVarExpr('Error'), [ - literal(name + " has a constructor which is not compatible with Dependency Injection. It should probably not be @Injectable().") - ])); -} -function isDelegatedMetadata(meta) { - return meta.delegateType !== undefined; -} -function isExpressionFactoryMetadata(meta) { - return meta.expression !== undefined; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Convert an object map with `Expression` values into a `LiteralMapExpr`. - */ -function mapToMapExpression(map) { - var result = Object.keys(map).map(function (key) { return ({ key: key, value: map[key], quoted: false }); }); - return literalMap(result); -} -/** - * Convert metadata into an `Expression` in the given `OutputContext`. - * - * This operation will handle arrays, references to symbols, or literal `null` or `undefined`. - */ -function convertMetaToOutput(meta, ctx) { - if (Array.isArray(meta)) { - return literalArr(meta.map(function (entry) { return convertMetaToOutput(entry, ctx); })); - } - if (meta instanceof StaticSymbol) { - return ctx.importExpr(meta); - } - if (meta == null) { - return literal(meta); - } - throw new Error("Internal error: Unsupported or unknown metadata: " + meta); -} -function typeWithParameters(type, numParams) { - var params = null; - if (numParams > 0) { - params = []; - for (var i = 0; i < numParams; i++) { - params.push(DYNAMIC_TYPE); - } - } - return expressionType(type, null, params); -} -var ANIMATE_SYMBOL_PREFIX = '@'; -function prepareSyntheticPropertyName(name) { - return "" + ANIMATE_SYMBOL_PREFIX + name; -} -function prepareSyntheticListenerName(name, phase) { - return "" + ANIMATE_SYMBOL_PREFIX + name + "." + phase; -} -function isSyntheticPropertyOrListener(name) { - return name.charAt(0) == ANIMATE_SYMBOL_PREFIX; -} -function getSyntheticPropertyName(name) { - // this will strip out listener phase values... - // @foo.start => @foo - var i = name.indexOf('.'); - name = i > 0 ? name.substring(0, i) : name; - if (name.charAt(0) !== ANIMATE_SYMBOL_PREFIX) { - name = ANIMATE_SYMBOL_PREFIX + name; - } - return name; -} -function prepareSyntheticListenerFunctionName(name, phase) { - return "animation_" + name + "_" + phase; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function compileInjectable(meta) { - var result = null; - var factoryMeta = { - name: meta.name, - type: meta.type, - deps: meta.ctorDeps, - injectFn: Identifiers.inject, - }; - if (meta.useClass !== undefined) { - // meta.useClass has two modes of operation. Either deps are specified, in which case `new` is - // used to instantiate the class with dependencies injected, or deps are not specified and - // the factory of the class is used to instantiate it. - // - // A special case exists for useClass: Type where Type is the injectable type itself and no - // deps are specified, in which case 'useClass' is effectively ignored. - var useClassOnSelf = meta.useClass.isEquivalent(meta.type); - var deps = undefined; - if (meta.userDeps !== undefined) { - deps = meta.userDeps; - } - if (deps !== undefined) { - // factory: () => new meta.useClass(...deps) - result = compileFactoryFunction(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, factoryMeta, { delegate: meta.useClass, delegateDeps: deps, delegateType: R3FactoryDelegateType.Class })); - } - else if (useClassOnSelf) { - result = compileFactoryFunction(factoryMeta); - } - else { - result = compileFactoryFunction(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, factoryMeta, { delegate: meta.useClass, delegateType: R3FactoryDelegateType.Factory })); - } - } - else if (meta.useFactory !== undefined) { - result = compileFactoryFunction(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, factoryMeta, { delegate: meta.useFactory, delegateDeps: meta.userDeps || [], delegateType: R3FactoryDelegateType.Function })); - } - else if (meta.useValue !== undefined) { - // Note: it's safe to use `meta.useValue` instead of the `USE_VALUE in meta` check used for - // client code because meta.useValue is an Expression which will be defined even if the actual - // value is undefined. - result = compileFactoryFunction(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, factoryMeta, { expression: meta.useValue })); - } - else if (meta.useExisting !== undefined) { - // useExisting is an `inject` call on the existing token. - result = compileFactoryFunction(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, factoryMeta, { expression: importExpr(Identifiers.inject).callFn([meta.useExisting]) })); - } - else { - result = compileFactoryFunction(factoryMeta); - } - var token = meta.type; - var providedIn = meta.providedIn; - var expression = importExpr(Identifiers.ɵɵdefineInjectable).callFn([mapToMapExpression({ token: token, factory: result.factory, providedIn: providedIn })]); - var type = new ExpressionType(importExpr(Identifiers.InjectableDef, [typeWithParameters(meta.type, meta.typeArgumentCount)])); - return { - expression: expression, - type: type, - statements: result.statements, - }; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function assertArrayOfStrings(identifier, value) { - if (value == null) { - return; - } - if (!Array.isArray(value)) { - throw new Error("Expected '" + identifier + "' to be an array of strings."); - } - for (var i = 0; i < value.length; i += 1) { - if (typeof value[i] !== 'string') { - throw new Error("Expected '" + identifier + "' to be an array of strings."); - } - } -} -var UNUSABLE_INTERPOLATION_REGEXPS = [ - /^\s*$/, - /[<>]/, - /^[{}]$/, - /&(#|[a-z])/i, - /^\/\//, -]; -function assertInterpolationSymbols(identifier, value) { - if (value != null && !(Array.isArray(value) && value.length == 2)) { - throw new Error("Expected '" + identifier + "' to be an array, [start, end]."); - } - else if (value != null) { - var start_1 = value[0]; - var end_1 = value[1]; - // Check for unusable interpolation symbols - UNUSABLE_INTERPOLATION_REGEXPS.forEach(function (regexp) { - if (regexp.test(start_1) || regexp.test(end_1)) { - throw new Error("['" + start_1 + "', '" + end_1 + "'] contains unusable interpolation symbol."); - } - }); - } -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var InterpolationConfig = /** @class */ (function () { - function InterpolationConfig(start, end) { - this.start = start; - this.end = end; - } - InterpolationConfig.fromArray = function (markers) { - if (!markers) { - return DEFAULT_INTERPOLATION_CONFIG; - } - assertInterpolationSymbols('interpolation', markers); - return new InterpolationConfig(markers[0], markers[1]); - }; - return InterpolationConfig; -}()); -var DEFAULT_INTERPOLATION_CONFIG = new InterpolationConfig('{{', '}}'); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// https://docs.google.com/document/d/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k/edit -var VERSION = 3; -var JS_B64_PREFIX = '# sourceMappingURL=data:application/json;base64,'; -var SourceMapGenerator = /** @class */ (function () { - function SourceMapGenerator(file) { - if (file === void 0) { file = null; } - this.file = file; - this.sourcesContent = new Map(); - this.lines = []; - this.lastCol0 = 0; - this.hasMappings = false; - } - // The content is `null` when the content is expected to be loaded using the URL - SourceMapGenerator.prototype.addSource = function (url, content) { - if (content === void 0) { content = null; } - if (!this.sourcesContent.has(url)) { - this.sourcesContent.set(url, content); - } - return this; - }; - SourceMapGenerator.prototype.addLine = function () { - this.lines.push([]); - this.lastCol0 = 0; - return this; - }; - SourceMapGenerator.prototype.addMapping = function (col0, sourceUrl, sourceLine0, sourceCol0) { - if (!this.currentLine) { - throw new Error("A line must be added before mappings can be added"); - } - if (sourceUrl != null && !this.sourcesContent.has(sourceUrl)) { - throw new Error("Unknown source file \"" + sourceUrl + "\""); - } - if (col0 == null) { - throw new Error("The column in the generated code must be provided"); - } - if (col0 < this.lastCol0) { - throw new Error("Mapping should be added in output order"); - } - if (sourceUrl && (sourceLine0 == null || sourceCol0 == null)) { - throw new Error("The source location must be provided when a source url is provided"); - } - this.hasMappings = true; - this.lastCol0 = col0; - this.currentLine.push({ col0: col0, sourceUrl: sourceUrl, sourceLine0: sourceLine0, sourceCol0: sourceCol0 }); - return this; - }; - Object.defineProperty(SourceMapGenerator.prototype, "currentLine", { - get: function () { return this.lines.slice(-1)[0]; }, - enumerable: true, - configurable: true - }); - SourceMapGenerator.prototype.toJSON = function () { - var _this = this; - if (!this.hasMappings) { - return null; - } - var sourcesIndex = new Map(); - var sources = []; - var sourcesContent = []; - Array.from(this.sourcesContent.keys()).forEach(function (url, i) { - sourcesIndex.set(url, i); - sources.push(url); - sourcesContent.push(_this.sourcesContent.get(url) || null); - }); - var mappings = ''; - var lastCol0 = 0; - var lastSourceIndex = 0; - var lastSourceLine0 = 0; - var lastSourceCol0 = 0; - this.lines.forEach(function (segments) { - lastCol0 = 0; - mappings += segments - .map(function (segment) { - // zero-based starting column of the line in the generated code - var segAsStr = toBase64VLQ(segment.col0 - lastCol0); - lastCol0 = segment.col0; - if (segment.sourceUrl != null) { - // zero-based index into the “sources” list - segAsStr += - toBase64VLQ(sourcesIndex.get(segment.sourceUrl) - lastSourceIndex); - lastSourceIndex = sourcesIndex.get(segment.sourceUrl); - // the zero-based starting line in the original source - segAsStr += toBase64VLQ(segment.sourceLine0 - lastSourceLine0); - lastSourceLine0 = segment.sourceLine0; - // the zero-based starting column in the original source - segAsStr += toBase64VLQ(segment.sourceCol0 - lastSourceCol0); - lastSourceCol0 = segment.sourceCol0; - } - return segAsStr; - }) - .join(','); - mappings += ';'; - }); - mappings = mappings.slice(0, -1); - return { - 'file': this.file || '', - 'version': VERSION, - 'sourceRoot': '', - 'sources': sources, - 'sourcesContent': sourcesContent, - 'mappings': mappings, - }; - }; - SourceMapGenerator.prototype.toJsComment = function () { - return this.hasMappings ? '//' + JS_B64_PREFIX + toBase64String(JSON.stringify(this, null, 0)) : - ''; - }; - return SourceMapGenerator; -}()); -function toBase64String(value) { - var b64 = ''; - value = utf8Encode(value); - for (var i = 0; i < value.length;) { - var i1 = value.charCodeAt(i++); - var i2 = value.charCodeAt(i++); - var i3 = value.charCodeAt(i++); - b64 += toBase64Digit(i1 >> 2); - b64 += toBase64Digit(((i1 & 3) << 4) | (isNaN(i2) ? 0 : i2 >> 4)); - b64 += isNaN(i2) ? '=' : toBase64Digit(((i2 & 15) << 2) | (i3 >> 6)); - b64 += isNaN(i2) || isNaN(i3) ? '=' : toBase64Digit(i3 & 63); - } - return b64; -} -function toBase64VLQ(value) { - value = value < 0 ? ((-value) << 1) + 1 : value << 1; - var out = ''; - do { - var digit = value & 31; - value = value >> 5; - if (value > 0) { - digit = digit | 32; - } - out += toBase64Digit(digit); - } while (value > 0); - return out; -} -var B64_DIGITS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'; -function toBase64Digit(value) { - if (value < 0 || value >= 64) { - throw new Error("Can only encode value in the range [0, 63]"); - } - return B64_DIGITS[value]; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _SINGLE_QUOTE_ESCAPE_STRING_RE = /'|\\|\n|\r|\$/g; -var _LEGAL_IDENTIFIER_RE = /^[$A-Z_][0-9A-Z_$]*$/i; -var _INDENT_WITH = ' '; -var CATCH_ERROR_VAR$1 = variable('error', null, null); -var CATCH_STACK_VAR$1 = variable('stack', null, null); -var _EmittedLine = /** @class */ (function () { - function _EmittedLine(indent) { - this.indent = indent; - this.partsLength = 0; - this.parts = []; - this.srcSpans = []; - } - return _EmittedLine; -}()); -var EmitterVisitorContext = /** @class */ (function () { - function EmitterVisitorContext(_indent) { - this._indent = _indent; - this._classes = []; - this._preambleLineCount = 0; - this._lines = [new _EmittedLine(_indent)]; - } - EmitterVisitorContext.createRoot = function () { return new EmitterVisitorContext(0); }; - Object.defineProperty(EmitterVisitorContext.prototype, "_currentLine", { - get: function () { return this._lines[this._lines.length - 1]; }, - enumerable: true, - configurable: true - }); - EmitterVisitorContext.prototype.println = function (from, lastPart) { - if (lastPart === void 0) { lastPart = ''; } - this.print(from || null, lastPart, true); - }; - EmitterVisitorContext.prototype.lineIsEmpty = function () { return this._currentLine.parts.length === 0; }; - EmitterVisitorContext.prototype.lineLength = function () { - return this._currentLine.indent * _INDENT_WITH.length + this._currentLine.partsLength; - }; - EmitterVisitorContext.prototype.print = function (from, part, newLine) { - if (newLine === void 0) { newLine = false; } - if (part.length > 0) { - this._currentLine.parts.push(part); - this._currentLine.partsLength += part.length; - this._currentLine.srcSpans.push(from && from.sourceSpan || null); - } - if (newLine) { - this._lines.push(new _EmittedLine(this._indent)); - } - }; - EmitterVisitorContext.prototype.removeEmptyLastLine = function () { - if (this.lineIsEmpty()) { - this._lines.pop(); - } - }; - EmitterVisitorContext.prototype.incIndent = function () { - this._indent++; - if (this.lineIsEmpty()) { - this._currentLine.indent = this._indent; - } - }; - EmitterVisitorContext.prototype.decIndent = function () { - this._indent--; - if (this.lineIsEmpty()) { - this._currentLine.indent = this._indent; - } - }; - EmitterVisitorContext.prototype.pushClass = function (clazz) { this._classes.push(clazz); }; - EmitterVisitorContext.prototype.popClass = function () { return this._classes.pop(); }; - Object.defineProperty(EmitterVisitorContext.prototype, "currentClass", { - get: function () { - return this._classes.length > 0 ? this._classes[this._classes.length - 1] : null; - }, - enumerable: true, - configurable: true - }); - EmitterVisitorContext.prototype.toSource = function () { - return this.sourceLines - .map(function (l) { return l.parts.length > 0 ? _createIndent(l.indent) + l.parts.join('') : ''; }) - .join('\n'); - }; - EmitterVisitorContext.prototype.toSourceMapGenerator = function (genFilePath, startsAtLine) { - if (startsAtLine === void 0) { startsAtLine = 0; } - var map = new SourceMapGenerator(genFilePath); - var firstOffsetMapped = false; - var mapFirstOffsetIfNeeded = function () { - if (!firstOffsetMapped) { - // Add a single space so that tools won't try to load the file from disk. - // Note: We are using virtual urls like `ng:///`, so we have to - // provide a content here. - map.addSource(genFilePath, ' ').addMapping(0, genFilePath, 0, 0); - firstOffsetMapped = true; - } - }; - for (var i = 0; i < startsAtLine; i++) { - map.addLine(); - mapFirstOffsetIfNeeded(); - } - this.sourceLines.forEach(function (line, lineIdx) { - map.addLine(); - var spans = line.srcSpans; - var parts = line.parts; - var col0 = line.indent * _INDENT_WITH.length; - var spanIdx = 0; - // skip leading parts without source spans - while (spanIdx < spans.length && !spans[spanIdx]) { - col0 += parts[spanIdx].length; - spanIdx++; - } - if (spanIdx < spans.length && lineIdx === 0 && col0 === 0) { - firstOffsetMapped = true; - } - else { - mapFirstOffsetIfNeeded(); - } - while (spanIdx < spans.length) { - var span = spans[spanIdx]; - var source = span.start.file; - var sourceLine = span.start.line; - var sourceCol = span.start.col; - map.addSource(source.url, source.content) - .addMapping(col0, source.url, sourceLine, sourceCol); - col0 += parts[spanIdx].length; - spanIdx++; - // assign parts without span or the same span to the previous segment - while (spanIdx < spans.length && (span === spans[spanIdx] || !spans[spanIdx])) { - col0 += parts[spanIdx].length; - spanIdx++; - } - } - }); - return map; - }; - EmitterVisitorContext.prototype.setPreambleLineCount = function (count) { return this._preambleLineCount = count; }; - EmitterVisitorContext.prototype.spanOf = function (line, column) { - var emittedLine = this._lines[line - this._preambleLineCount]; - if (emittedLine) { - var columnsLeft = column - _createIndent(emittedLine.indent).length; - for (var partIndex = 0; partIndex < emittedLine.parts.length; partIndex++) { - var part = emittedLine.parts[partIndex]; - if (part.length > columnsLeft) { - return emittedLine.srcSpans[partIndex]; - } - columnsLeft -= part.length; - } - } - return null; - }; - Object.defineProperty(EmitterVisitorContext.prototype, "sourceLines", { - get: function () { - if (this._lines.length && this._lines[this._lines.length - 1].parts.length === 0) { - return this._lines.slice(0, -1); - } - return this._lines; - }, - enumerable: true, - configurable: true - }); - return EmitterVisitorContext; -}()); -var AbstractEmitterVisitor = /** @class */ (function () { - function AbstractEmitterVisitor(_escapeDollarInStrings) { - this._escapeDollarInStrings = _escapeDollarInStrings; - } - AbstractEmitterVisitor.prototype.visitExpressionStmt = function (stmt, ctx) { - stmt.expr.visitExpression(this, ctx); - ctx.println(stmt, ';'); - return null; - }; - AbstractEmitterVisitor.prototype.visitReturnStmt = function (stmt, ctx) { - ctx.print(stmt, "return "); - stmt.value.visitExpression(this, ctx); - ctx.println(stmt, ';'); - return null; - }; - AbstractEmitterVisitor.prototype.visitIfStmt = function (stmt, ctx) { - ctx.print(stmt, "if ("); - stmt.condition.visitExpression(this, ctx); - ctx.print(stmt, ") {"); - var hasElseCase = stmt.falseCase != null && stmt.falseCase.length > 0; - if (stmt.trueCase.length <= 1 && !hasElseCase) { - ctx.print(stmt, " "); - this.visitAllStatements(stmt.trueCase, ctx); - ctx.removeEmptyLastLine(); - ctx.print(stmt, " "); - } - else { - ctx.println(); - ctx.incIndent(); - this.visitAllStatements(stmt.trueCase, ctx); - ctx.decIndent(); - if (hasElseCase) { - ctx.println(stmt, "} else {"); - ctx.incIndent(); - this.visitAllStatements(stmt.falseCase, ctx); - ctx.decIndent(); - } - } - ctx.println(stmt, "}"); - return null; - }; - AbstractEmitterVisitor.prototype.visitThrowStmt = function (stmt, ctx) { - ctx.print(stmt, "throw "); - stmt.error.visitExpression(this, ctx); - ctx.println(stmt, ";"); - return null; - }; - AbstractEmitterVisitor.prototype.visitCommentStmt = function (stmt, ctx) { - if (stmt.multiline) { - ctx.println(stmt, "/* " + stmt.comment + " */"); - } - else { - stmt.comment.split('\n').forEach(function (line) { ctx.println(stmt, "// " + line); }); - } - return null; - }; - AbstractEmitterVisitor.prototype.visitJSDocCommentStmt = function (stmt, ctx) { - ctx.println(stmt, "/*" + stmt.toString() + "*/"); - return null; - }; - AbstractEmitterVisitor.prototype.visitWriteVarExpr = function (expr, ctx) { - var lineWasEmpty = ctx.lineIsEmpty(); - if (!lineWasEmpty) { - ctx.print(expr, '('); - } - ctx.print(expr, expr.name + " = "); - expr.value.visitExpression(this, ctx); - if (!lineWasEmpty) { - ctx.print(expr, ')'); - } - return null; - }; - AbstractEmitterVisitor.prototype.visitWriteKeyExpr = function (expr, ctx) { - var lineWasEmpty = ctx.lineIsEmpty(); - if (!lineWasEmpty) { - ctx.print(expr, '('); - } - expr.receiver.visitExpression(this, ctx); - ctx.print(expr, "["); - expr.index.visitExpression(this, ctx); - ctx.print(expr, "] = "); - expr.value.visitExpression(this, ctx); - if (!lineWasEmpty) { - ctx.print(expr, ')'); - } - return null; - }; - AbstractEmitterVisitor.prototype.visitWritePropExpr = function (expr, ctx) { - var lineWasEmpty = ctx.lineIsEmpty(); - if (!lineWasEmpty) { - ctx.print(expr, '('); - } - expr.receiver.visitExpression(this, ctx); - ctx.print(expr, "." + expr.name + " = "); - expr.value.visitExpression(this, ctx); - if (!lineWasEmpty) { - ctx.print(expr, ')'); - } - return null; - }; - AbstractEmitterVisitor.prototype.visitInvokeMethodExpr = function (expr, ctx) { - expr.receiver.visitExpression(this, ctx); - var name = expr.name; - if (expr.builtin != null) { - name = this.getBuiltinMethodName(expr.builtin); - if (name == null) { - // some builtins just mean to skip the call. - return null; - } - } - ctx.print(expr, "." + name + "("); - this.visitAllExpressions(expr.args, ctx, ","); - ctx.print(expr, ")"); - return null; - }; - AbstractEmitterVisitor.prototype.visitInvokeFunctionExpr = function (expr, ctx) { - expr.fn.visitExpression(this, ctx); - ctx.print(expr, "("); - this.visitAllExpressions(expr.args, ctx, ','); - ctx.print(expr, ")"); - return null; - }; - AbstractEmitterVisitor.prototype.visitWrappedNodeExpr = function (ast, ctx) { - throw new Error('Abstract emitter cannot visit WrappedNodeExpr.'); - }; - AbstractEmitterVisitor.prototype.visitTypeofExpr = function (expr, ctx) { - ctx.print(expr, 'typeof '); - expr.expr.visitExpression(this, ctx); - }; - AbstractEmitterVisitor.prototype.visitReadVarExpr = function (ast, ctx) { - var varName = ast.name; - if (ast.builtin != null) { - switch (ast.builtin) { - case BuiltinVar.Super: - varName = 'super'; - break; - case BuiltinVar.This: - varName = 'this'; - break; - case BuiltinVar.CatchError: - varName = CATCH_ERROR_VAR$1.name; - break; - case BuiltinVar.CatchStack: - varName = CATCH_STACK_VAR$1.name; - break; - default: - throw new Error("Unknown builtin variable " + ast.builtin); - } - } - ctx.print(ast, varName); - return null; - }; - AbstractEmitterVisitor.prototype.visitInstantiateExpr = function (ast, ctx) { - ctx.print(ast, "new "); - ast.classExpr.visitExpression(this, ctx); - ctx.print(ast, "("); - this.visitAllExpressions(ast.args, ctx, ','); - ctx.print(ast, ")"); - return null; - }; - AbstractEmitterVisitor.prototype.visitLiteralExpr = function (ast, ctx) { - var value = ast.value; - if (typeof value === 'string') { - ctx.print(ast, escapeIdentifier(value, this._escapeDollarInStrings)); - } - else { - ctx.print(ast, "" + value); - } - return null; - }; - AbstractEmitterVisitor.prototype.visitConditionalExpr = function (ast, ctx) { - ctx.print(ast, "("); - ast.condition.visitExpression(this, ctx); - ctx.print(ast, '? '); - ast.trueCase.visitExpression(this, ctx); - ctx.print(ast, ': '); - ast.falseCase.visitExpression(this, ctx); - ctx.print(ast, ")"); - return null; - }; - AbstractEmitterVisitor.prototype.visitNotExpr = function (ast, ctx) { - ctx.print(ast, '!'); - ast.condition.visitExpression(this, ctx); - return null; - }; - AbstractEmitterVisitor.prototype.visitAssertNotNullExpr = function (ast, ctx) { - ast.condition.visitExpression(this, ctx); - return null; - }; - AbstractEmitterVisitor.prototype.visitBinaryOperatorExpr = function (ast, ctx) { - var opStr; - switch (ast.operator) { - case BinaryOperator.Equals: - opStr = '=='; - break; - case BinaryOperator.Identical: - opStr = '==='; - break; - case BinaryOperator.NotEquals: - opStr = '!='; - break; - case BinaryOperator.NotIdentical: - opStr = '!=='; - break; - case BinaryOperator.And: - opStr = '&&'; - break; - case BinaryOperator.BitwiseAnd: - opStr = '&'; - break; - case BinaryOperator.Or: - opStr = '||'; - break; - case BinaryOperator.Plus: - opStr = '+'; - break; - case BinaryOperator.Minus: - opStr = '-'; - break; - case BinaryOperator.Divide: - opStr = '/'; - break; - case BinaryOperator.Multiply: - opStr = '*'; - break; - case BinaryOperator.Modulo: - opStr = '%'; - break; - case BinaryOperator.Lower: - opStr = '<'; - break; - case BinaryOperator.LowerEquals: - opStr = '<='; - break; - case BinaryOperator.Bigger: - opStr = '>'; - break; - case BinaryOperator.BiggerEquals: - opStr = '>='; - break; - default: - throw new Error("Unknown operator " + ast.operator); - } - if (ast.parens) - ctx.print(ast, "("); - ast.lhs.visitExpression(this, ctx); - ctx.print(ast, " " + opStr + " "); - ast.rhs.visitExpression(this, ctx); - if (ast.parens) - ctx.print(ast, ")"); - return null; - }; - AbstractEmitterVisitor.prototype.visitReadPropExpr = function (ast, ctx) { - ast.receiver.visitExpression(this, ctx); - ctx.print(ast, "."); - ctx.print(ast, ast.name); - return null; - }; - AbstractEmitterVisitor.prototype.visitReadKeyExpr = function (ast, ctx) { - ast.receiver.visitExpression(this, ctx); - ctx.print(ast, "["); - ast.index.visitExpression(this, ctx); - ctx.print(ast, "]"); - return null; - }; - AbstractEmitterVisitor.prototype.visitLiteralArrayExpr = function (ast, ctx) { - ctx.print(ast, "["); - this.visitAllExpressions(ast.entries, ctx, ','); - ctx.print(ast, "]"); - return null; - }; - AbstractEmitterVisitor.prototype.visitLiteralMapExpr = function (ast, ctx) { - var _this = this; - ctx.print(ast, "{"); - this.visitAllObjects(function (entry) { - ctx.print(ast, escapeIdentifier(entry.key, _this._escapeDollarInStrings, entry.quoted) + ":"); - entry.value.visitExpression(_this, ctx); - }, ast.entries, ctx, ','); - ctx.print(ast, "}"); - return null; - }; - AbstractEmitterVisitor.prototype.visitCommaExpr = function (ast, ctx) { - ctx.print(ast, '('); - this.visitAllExpressions(ast.parts, ctx, ','); - ctx.print(ast, ')'); - return null; - }; - AbstractEmitterVisitor.prototype.visitAllExpressions = function (expressions, ctx, separator) { - var _this = this; - this.visitAllObjects(function (expr) { return expr.visitExpression(_this, ctx); }, expressions, ctx, separator); - }; - AbstractEmitterVisitor.prototype.visitAllObjects = function (handler, expressions, ctx, separator) { - var incrementedIndent = false; - for (var i = 0; i < expressions.length; i++) { - if (i > 0) { - if (ctx.lineLength() > 80) { - ctx.print(null, separator, true); - if (!incrementedIndent) { - // continuation are marked with double indent. - ctx.incIndent(); - ctx.incIndent(); - incrementedIndent = true; - } - } - else { - ctx.print(null, separator, false); - } - } - handler(expressions[i]); - } - if (incrementedIndent) { - // continuation are marked with double indent. - ctx.decIndent(); - ctx.decIndent(); - } - }; - AbstractEmitterVisitor.prototype.visitAllStatements = function (statements, ctx) { - var _this = this; - statements.forEach(function (stmt) { return stmt.visitStatement(_this, ctx); }); - }; - return AbstractEmitterVisitor; -}()); -function escapeIdentifier(input, escapeDollar, alwaysQuote) { - if (alwaysQuote === void 0) { alwaysQuote = true; } - if (input == null) { - return null; - } - var body = input.replace(_SINGLE_QUOTE_ESCAPE_STRING_RE, function () { - var match = []; - for (var _i = 0; _i < arguments.length; _i++) { - match[_i] = arguments[_i]; - } - if (match[0] == '$') { - return escapeDollar ? '\\$' : '$'; - } - else if (match[0] == '\n') { - return '\\n'; - } - else if (match[0] == '\r') { - return '\\r'; - } - else { - return "\\" + match[0]; - } - }); - var requiresQuotes = alwaysQuote || !_LEGAL_IDENTIFIER_RE.test(body); - return requiresQuotes ? "'" + body + "'" : body; -} -function _createIndent(count) { - var res = ''; - for (var i = 0; i < count; i++) { - res += _INDENT_WITH; - } - return res; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var AbstractJsEmitterVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(AbstractJsEmitterVisitor, _super); - function AbstractJsEmitterVisitor() { - return _super.call(this, false) || this; - } - AbstractJsEmitterVisitor.prototype.visitDeclareClassStmt = function (stmt, ctx) { - var _this = this; - ctx.pushClass(stmt); - this._visitClassConstructor(stmt, ctx); - if (stmt.parent != null) { - ctx.print(stmt, stmt.name + ".prototype = Object.create("); - stmt.parent.visitExpression(this, ctx); - ctx.println(stmt, ".prototype);"); - } - stmt.getters.forEach(function (getter) { return _this._visitClassGetter(stmt, getter, ctx); }); - stmt.methods.forEach(function (method) { return _this._visitClassMethod(stmt, method, ctx); }); - ctx.popClass(); - return null; - }; - AbstractJsEmitterVisitor.prototype._visitClassConstructor = function (stmt, ctx) { - ctx.print(stmt, "function " + stmt.name + "("); - if (stmt.constructorMethod != null) { - this._visitParams(stmt.constructorMethod.params, ctx); - } - ctx.println(stmt, ") {"); - ctx.incIndent(); - if (stmt.constructorMethod != null) { - if (stmt.constructorMethod.body.length > 0) { - ctx.println(stmt, "var self = this;"); - this.visitAllStatements(stmt.constructorMethod.body, ctx); - } - } - ctx.decIndent(); - ctx.println(stmt, "}"); - }; - AbstractJsEmitterVisitor.prototype._visitClassGetter = function (stmt, getter, ctx) { - ctx.println(stmt, "Object.defineProperty(" + stmt.name + ".prototype, '" + getter.name + "', { get: function() {"); - ctx.incIndent(); - if (getter.body.length > 0) { - ctx.println(stmt, "var self = this;"); - this.visitAllStatements(getter.body, ctx); - } - ctx.decIndent(); - ctx.println(stmt, "}});"); - }; - AbstractJsEmitterVisitor.prototype._visitClassMethod = function (stmt, method, ctx) { - ctx.print(stmt, stmt.name + ".prototype." + method.name + " = function("); - this._visitParams(method.params, ctx); - ctx.println(stmt, ") {"); - ctx.incIndent(); - if (method.body.length > 0) { - ctx.println(stmt, "var self = this;"); - this.visitAllStatements(method.body, ctx); - } - ctx.decIndent(); - ctx.println(stmt, "};"); - }; - AbstractJsEmitterVisitor.prototype.visitWrappedNodeExpr = function (ast, ctx) { - throw new Error('Cannot emit a WrappedNodeExpr in Javascript.'); - }; - AbstractJsEmitterVisitor.prototype.visitReadVarExpr = function (ast, ctx) { - if (ast.builtin === BuiltinVar.This) { - ctx.print(ast, 'self'); - } - else if (ast.builtin === BuiltinVar.Super) { - throw new Error("'super' needs to be handled at a parent ast node, not at the variable level!"); - } - else { - _super.prototype.visitReadVarExpr.call(this, ast, ctx); - } - return null; - }; - AbstractJsEmitterVisitor.prototype.visitDeclareVarStmt = function (stmt, ctx) { - ctx.print(stmt, "var " + stmt.name); - if (stmt.value) { - ctx.print(stmt, ' = '); - stmt.value.visitExpression(this, ctx); - } - ctx.println(stmt, ";"); - return null; - }; - AbstractJsEmitterVisitor.prototype.visitCastExpr = function (ast, ctx) { - ast.value.visitExpression(this, ctx); - return null; - }; - AbstractJsEmitterVisitor.prototype.visitInvokeFunctionExpr = function (expr, ctx) { - var fnExpr = expr.fn; - if (fnExpr instanceof ReadVarExpr && fnExpr.builtin === BuiltinVar.Super) { - ctx.currentClass.parent.visitExpression(this, ctx); - ctx.print(expr, ".call(this"); - if (expr.args.length > 0) { - ctx.print(expr, ", "); - this.visitAllExpressions(expr.args, ctx, ','); - } - ctx.print(expr, ")"); - } - else { - _super.prototype.visitInvokeFunctionExpr.call(this, expr, ctx); - } - return null; - }; - AbstractJsEmitterVisitor.prototype.visitFunctionExpr = function (ast, ctx) { - ctx.print(ast, "function" + (ast.name ? ' ' + ast.name : '') + "("); - this._visitParams(ast.params, ctx); - ctx.println(ast, ") {"); - ctx.incIndent(); - this.visitAllStatements(ast.statements, ctx); - ctx.decIndent(); - ctx.print(ast, "}"); - return null; - }; - AbstractJsEmitterVisitor.prototype.visitDeclareFunctionStmt = function (stmt, ctx) { - ctx.print(stmt, "function " + stmt.name + "("); - this._visitParams(stmt.params, ctx); - ctx.println(stmt, ") {"); - ctx.incIndent(); - this.visitAllStatements(stmt.statements, ctx); - ctx.decIndent(); - ctx.println(stmt, "}"); - return null; - }; - AbstractJsEmitterVisitor.prototype.visitTryCatchStmt = function (stmt, ctx) { - ctx.println(stmt, "try {"); - ctx.incIndent(); - this.visitAllStatements(stmt.bodyStmts, ctx); - ctx.decIndent(); - ctx.println(stmt, "} catch (" + CATCH_ERROR_VAR$1.name + ") {"); - ctx.incIndent(); - var catchStmts = [CATCH_STACK_VAR$1.set(CATCH_ERROR_VAR$1.prop('stack')).toDeclStmt(null, [ - StmtModifier.Final - ])].concat(stmt.catchStmts); - this.visitAllStatements(catchStmts, ctx); - ctx.decIndent(); - ctx.println(stmt, "}"); - return null; - }; - AbstractJsEmitterVisitor.prototype._visitParams = function (params, ctx) { - this.visitAllObjects(function (param) { return ctx.print(null, param.name); }, params, ctx, ','); - }; - AbstractJsEmitterVisitor.prototype.getBuiltinMethodName = function (method) { - var name; - switch (method) { - case BuiltinMethod.ConcatArray: - name = 'concat'; - break; - case BuiltinMethod.SubscribeObservable: - name = 'subscribe'; - break; - case BuiltinMethod.Bind: - name = 'bind'; - break; - default: - throw new Error("Unknown builtin method: " + method); - } - return name; - }; - return AbstractJsEmitterVisitor; -}(AbstractEmitterVisitor)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A helper class to manage the evaluation of JIT generated code. - */ -var JitEvaluator = /** @class */ (function () { - function JitEvaluator() { - } - /** - * - * @param sourceUrl The URL of the generated code. - * @param statements An array of Angular statement AST nodes to be evaluated. - * @param reflector A helper used when converting the statements to executable code. - * @param createSourceMaps If true then create a source-map for the generated code and include it - * inline as a source-map comment. - * @returns A map of all the variables in the generated code. - */ - JitEvaluator.prototype.evaluateStatements = function (sourceUrl, statements, reflector, createSourceMaps) { - var converter = new JitEmitterVisitor(reflector); - var ctx = EmitterVisitorContext.createRoot(); - // Ensure generated code is in strict mode - if (statements.length > 0 && !isUseStrictStatement(statements[0])) { - statements = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([ - literal('use strict').toStmt() - ], statements); - } - converter.visitAllStatements(statements, ctx); - converter.createReturnStmt(ctx); - return this.evaluateCode(sourceUrl, ctx, converter.getArgs(), createSourceMaps); - }; - /** - * Evaluate a piece of JIT generated code. - * @param sourceUrl The URL of this generated code. - * @param ctx A context object that contains an AST of the code to be evaluated. - * @param vars A map containing the names and values of variables that the evaluated code might - * reference. - * @param createSourceMap If true then create a source-map for the generated code and include it - * inline as a source-map comment. - * @returns The result of evaluating the code. - */ - JitEvaluator.prototype.evaluateCode = function (sourceUrl, ctx, vars, createSourceMap) { - var fnBody = "\"use strict\";" + ctx.toSource() + "\n//# sourceURL=" + sourceUrl; - var fnArgNames = []; - var fnArgValues = []; - for (var argName in vars) { - fnArgValues.push(vars[argName]); - fnArgNames.push(argName); - } - if (createSourceMap) { - // using `new Function(...)` generates a header, 1 line of no arguments, 2 lines otherwise - // E.g. ``` - // function anonymous(a,b,c - // /**/) { ... }``` - // We don't want to hard code this fact, so we auto detect it via an empty function first. - var emptyFn = new (Function.bind.apply(Function, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([void 0], fnArgNames.concat('return null;'))))().toString(); - var headerLines = emptyFn.slice(0, emptyFn.indexOf('return null;')).split('\n').length - 1; - fnBody += "\n" + ctx.toSourceMapGenerator(sourceUrl, headerLines).toJsComment(); - } - var fn = new (Function.bind.apply(Function, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([void 0], fnArgNames.concat(fnBody))))(); - return this.executeFunction(fn, fnArgValues); - }; - /** - * Execute a JIT generated function by calling it. - * - * This method can be overridden in tests to capture the functions that are generated - * by this `JitEvaluator` class. - * - * @param fn A function to execute. - * @param args The arguments to pass to the function being executed. - * @returns The return value of the executed function. - */ - JitEvaluator.prototype.executeFunction = function (fn, args) { return fn.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(args)); }; - return JitEvaluator; -}()); -/** - * An Angular AST visitor that converts AST nodes into executable JavaScript code. - */ -var JitEmitterVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(JitEmitterVisitor, _super); - function JitEmitterVisitor(reflector) { - var _this = _super.call(this) || this; - _this.reflector = reflector; - _this._evalArgNames = []; - _this._evalArgValues = []; - _this._evalExportedVars = []; - return _this; - } - JitEmitterVisitor.prototype.createReturnStmt = function (ctx) { - var stmt = new ReturnStatement(new LiteralMapExpr(this._evalExportedVars.map(function (resultVar) { return new LiteralMapEntry(resultVar, variable(resultVar), false); }))); - stmt.visitStatement(this, ctx); - }; - JitEmitterVisitor.prototype.getArgs = function () { - var result = {}; - for (var i = 0; i < this._evalArgNames.length; i++) { - result[this._evalArgNames[i]] = this._evalArgValues[i]; - } - return result; - }; - JitEmitterVisitor.prototype.visitExternalExpr = function (ast, ctx) { - this._emitReferenceToExternal(ast, this.reflector.resolveExternalReference(ast.value), ctx); - return null; - }; - JitEmitterVisitor.prototype.visitWrappedNodeExpr = function (ast, ctx) { - this._emitReferenceToExternal(ast, ast.node, ctx); - return null; - }; - JitEmitterVisitor.prototype.visitDeclareVarStmt = function (stmt, ctx) { - if (stmt.hasModifier(StmtModifier.Exported)) { - this._evalExportedVars.push(stmt.name); - } - return _super.prototype.visitDeclareVarStmt.call(this, stmt, ctx); - }; - JitEmitterVisitor.prototype.visitDeclareFunctionStmt = function (stmt, ctx) { - if (stmt.hasModifier(StmtModifier.Exported)) { - this._evalExportedVars.push(stmt.name); - } - return _super.prototype.visitDeclareFunctionStmt.call(this, stmt, ctx); - }; - JitEmitterVisitor.prototype.visitDeclareClassStmt = function (stmt, ctx) { - if (stmt.hasModifier(StmtModifier.Exported)) { - this._evalExportedVars.push(stmt.name); - } - return _super.prototype.visitDeclareClassStmt.call(this, stmt, ctx); - }; - JitEmitterVisitor.prototype._emitReferenceToExternal = function (ast, value, ctx) { - var id = this._evalArgValues.indexOf(value); - if (id === -1) { - id = this._evalArgValues.length; - this._evalArgValues.push(value); - var name_1 = identifierName({ reference: value }) || 'val'; - this._evalArgNames.push("jit_" + name_1 + "_" + id); - } - ctx.print(ast, this._evalArgNames[id]); - }; - return JitEmitterVisitor; -}(AbstractJsEmitterVisitor)); -function isUseStrictStatement(statement) { - return statement.isEquivalent(literal('use strict').toStmt()); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Implementation of `CompileReflector` which resolves references to @angular/core - * symbols at runtime, according to a consumer-provided mapping. - * - * Only supports `resolveExternalReference`, all other methods throw. - */ -var R3JitReflector = /** @class */ (function () { - function R3JitReflector(context) { - this.context = context; - } - R3JitReflector.prototype.resolveExternalReference = function (ref) { - // This reflector only handles @angular/core imports. - if (ref.moduleName !== '@angular/core') { - throw new Error("Cannot resolve external reference to " + ref.moduleName + ", only references to @angular/core are supported."); - } - if (!this.context.hasOwnProperty(ref.name)) { - throw new Error("No value provided for @angular/core symbol '" + ref.name + "'."); - } - return this.context[ref.name]; - }; - R3JitReflector.prototype.parameters = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.annotations = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.shallowAnnotations = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.tryAnnotations = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.propMetadata = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.hasLifecycleHook = function (type, lcProperty) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.guards = function (typeOrFunc) { throw new Error('Not implemented.'); }; - R3JitReflector.prototype.componentModuleUrl = function (type, cmpMetadata) { throw new Error('Not implemented.'); }; - return R3JitReflector; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * Construct an `R3NgModuleDef` for the given `R3NgModuleMetadata`. - */ -function compileNgModule(meta) { - var moduleType = meta.type, bootstrap = meta.bootstrap, declarations = meta.declarations, imports = meta.imports, exports = meta.exports, schemas = meta.schemas, containsForwardDecls = meta.containsForwardDecls, emitInline = meta.emitInline, id = meta.id; - var additionalStatements = []; - var definitionMap = { - type: moduleType - }; - // Only generate the keys in the metadata if the arrays have values. - if (bootstrap.length) { - definitionMap.bootstrap = refsToArray(bootstrap, containsForwardDecls); - } - // If requested to emit scope information inline, pass the declarations, imports and exports to - // the `ɵɵdefineNgModule` call. The JIT compilation uses this. - if (emitInline) { - if (declarations.length) { - definitionMap.declarations = refsToArray(declarations, containsForwardDecls); - } - if (imports.length) { - definitionMap.imports = refsToArray(imports, containsForwardDecls); - } - if (exports.length) { - definitionMap.exports = refsToArray(exports, containsForwardDecls); - } - } - // If not emitting inline, the scope information is not passed into `ɵɵdefineNgModule` as it would - // prevent tree-shaking of the declarations, imports and exports references. - else { - var setNgModuleScopeCall = generateSetNgModuleScopeCall(meta); - if (setNgModuleScopeCall !== null) { - additionalStatements.push(setNgModuleScopeCall); - } - } - if (schemas && schemas.length) { - definitionMap.schemas = literalArr(schemas.map(function (ref) { return ref.value; })); - } - if (id) { - definitionMap.id = id; - } - var expression = importExpr(Identifiers$1.defineNgModule).callFn([mapToMapExpression(definitionMap)]); - var type = new ExpressionType(importExpr(Identifiers$1.NgModuleDefWithMeta, [ - new ExpressionType(moduleType), tupleTypeOf(declarations), tupleTypeOf(imports), - tupleTypeOf(exports) - ])); - return { expression: expression, type: type, additionalStatements: additionalStatements }; -} -/** - * Generates a function call to `ɵɵsetNgModuleScope` with all necessary information so that the - * transitive module scope can be computed during runtime in JIT mode. This call is marked pure - * such that the references to declarations, imports and exports may be elided causing these - * symbols to become tree-shakeable. - */ -function generateSetNgModuleScopeCall(meta) { - var moduleType = meta.type, declarations = meta.declarations, imports = meta.imports, exports = meta.exports, containsForwardDecls = meta.containsForwardDecls; - var scopeMap = {}; - if (declarations.length) { - scopeMap.declarations = refsToArray(declarations, containsForwardDecls); - } - if (imports.length) { - scopeMap.imports = refsToArray(imports, containsForwardDecls); - } - if (exports.length) { - scopeMap.exports = refsToArray(exports, containsForwardDecls); - } - if (Object.keys(scopeMap).length === 0) { - return null; - } - var fnCall = new InvokeFunctionExpr( - /* fn */ importExpr(Identifiers$1.setNgModuleScope), - /* args */ [moduleType, mapToMapExpression(scopeMap)], - /* type */ undefined, - /* sourceSpan */ undefined, - /* pure */ true); - return fnCall.toStmt(); -} -function compileInjector(meta) { - var result = compileFactoryFunction({ - name: meta.name, - type: meta.type, - deps: meta.deps, - injectFn: Identifiers$1.inject, - }); - var definitionMap = { - factory: result.factory, - }; - if (meta.providers !== null) { - definitionMap.providers = meta.providers; - } - if (meta.imports.length > 0) { - definitionMap.imports = literalArr(meta.imports); - } - var expression = importExpr(Identifiers$1.defineInjector).callFn([mapToMapExpression(definitionMap)]); - var type = new ExpressionType(importExpr(Identifiers$1.InjectorDef, [new ExpressionType(meta.type)])); - return { expression: expression, type: type, statements: result.statements }; -} -// TODO(alxhub): integrate this with `compileNgModule`. Currently the two are separate operations. -function compileNgModuleFromRender2(ctx, ngModule, injectableCompiler) { - var className = identifierName(ngModule.type); - var rawImports = ngModule.rawImports ? [ngModule.rawImports] : []; - var rawExports = ngModule.rawExports ? [ngModule.rawExports] : []; - var injectorDefArg = mapLiteral({ - 'factory': injectableCompiler.factoryFor({ type: ngModule.type, symbol: ngModule.type.reference }, ctx), - 'providers': convertMetaToOutput(ngModule.rawProviders, ctx), - 'imports': convertMetaToOutput(Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(rawImports, rawExports), ctx), - }); - var injectorDef = importExpr(Identifiers$1.defineInjector).callFn([injectorDefArg]); - ctx.statements.push(new ClassStmt( - /* name */ className, - /* parent */ null, - /* fields */ [new ClassField( - /* name */ 'ngInjectorDef', - /* type */ INFERRED_TYPE, - /* modifiers */ [StmtModifier.Static], - /* initializer */ injectorDef)], - /* getters */ [], - /* constructorMethod */ new ClassMethod(null, [], []), - /* methods */ [])); -} -function accessExportScope(module) { - var selectorScope = new ReadPropExpr(module, 'ngModuleDef'); - return new ReadPropExpr(selectorScope, 'exported'); -} -function tupleTypeOf(exp) { - var types = exp.map(function (ref) { return typeofExpr(ref.type); }); - return exp.length > 0 ? expressionType(literalArr(types)) : NONE_TYPE; -} -function refsToArray(refs, shouldForwardDeclare) { - var values = literalArr(refs.map(function (ref) { return ref.value; })); - return shouldForwardDeclare ? fn([], [new ReturnStatement(values)]) : values; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -function compilePipeFromMetadata(metadata) { - var definitionMapValues = []; - // e.g. `name: 'myPipe'` - definitionMapValues.push({ key: 'name', value: literal(metadata.pipeName), quoted: false }); - // e.g. `type: MyPipe` - definitionMapValues.push({ key: 'type', value: metadata.type, quoted: false }); - var templateFactory = compileFactoryFunction({ - name: metadata.name, - type: metadata.type, - deps: metadata.deps, - injectFn: Identifiers$1.directiveInject, - }, true); - definitionMapValues.push({ key: 'factory', value: templateFactory.factory, quoted: false }); - // e.g. `pure: true` - definitionMapValues.push({ key: 'pure', value: literal(metadata.pure), quoted: false }); - var expression = importExpr(Identifiers$1.definePipe).callFn([literalMap(definitionMapValues)]); - var type = new ExpressionType(importExpr(Identifiers$1.PipeDefWithMeta, [ - typeWithParameters(metadata.type, metadata.typeArgumentCount), - new ExpressionType(new LiteralExpr(metadata.pipeName)), - ])); - return { expression: expression, type: type, statements: templateFactory.statements }; -} -/** - * Write a pipe definition to the output context. - */ -function compilePipeFromRender2(outputCtx, pipe, reflector) { - var definitionMapValues = []; - var name = identifierName(pipe.type); - if (!name) { - return error("Cannot resolve the name of " + pipe.type); - } - var metadata = { - name: name, - pipeName: pipe.name, - type: outputCtx.importExpr(pipe.type.reference), - typeArgumentCount: 0, - deps: dependenciesFromGlobalMetadata(pipe.type, outputCtx, reflector), - pure: pipe.pure, - }; - var res = compilePipeFromMetadata(metadata); - var definitionField = outputCtx.constantPool.propertyNameOf(3 /* Pipe */); - outputCtx.statements.push(new ClassStmt( - /* name */ name, - /* parent */ null, - /* fields */ [new ClassField( - /* name */ definitionField, - /* type */ INFERRED_TYPE, - /* modifiers */ [StmtModifier.Static], - /* initializer */ res.expression)], - /* getters */ [], - /* constructorMethod */ new ClassMethod(null, [], []), - /* methods */ [])); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var ParserError = /** @class */ (function () { - function ParserError(message, input, errLocation, ctxLocation) { - this.input = input; - this.errLocation = errLocation; - this.ctxLocation = ctxLocation; - this.message = "Parser Error: " + message + " " + errLocation + " [" + input + "] in " + ctxLocation; - } - return ParserError; -}()); -var ParseSpan = /** @class */ (function () { - function ParseSpan(start, end) { - this.start = start; - this.end = end; - } - return ParseSpan; -}()); -var AST = /** @class */ (function () { - function AST(span) { - this.span = span; - } - AST.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return null; - }; - AST.prototype.toString = function () { return 'AST'; }; - return AST; -}()); -/** - * Represents a quoted expression of the form: - * - * quote = prefix `:` uninterpretedExpression - * prefix = identifier - * uninterpretedExpression = arbitrary string - * - * A quoted expression is meant to be pre-processed by an AST transformer that - * converts it into another AST that no longer contains quoted expressions. - * It is meant to allow third-party developers to extend Angular template - * expression language. The `uninterpretedExpression` part of the quote is - * therefore not interpreted by the Angular's own expression parser. - */ -var Quote = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Quote, _super); - function Quote(span, prefix, uninterpretedExpression, location) { - var _this = _super.call(this, span) || this; - _this.prefix = prefix; - _this.uninterpretedExpression = uninterpretedExpression; - _this.location = location; - return _this; - } - Quote.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitQuote(this, context); - }; - Quote.prototype.toString = function () { return 'Quote'; }; - return Quote; -}(AST)); -var EmptyExpr = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(EmptyExpr, _super); - function EmptyExpr() { - return _super !== null && _super.apply(this, arguments) || this; - } - EmptyExpr.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - // do nothing - }; - return EmptyExpr; -}(AST)); -var ImplicitReceiver = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ImplicitReceiver, _super); - function ImplicitReceiver() { - return _super !== null && _super.apply(this, arguments) || this; - } - ImplicitReceiver.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitImplicitReceiver(this, context); - }; - return ImplicitReceiver; -}(AST)); -/** - * Multiple expressions separated by a semicolon. - */ -var Chain = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Chain, _super); - function Chain(span, expressions) { - var _this = _super.call(this, span) || this; - _this.expressions = expressions; - return _this; - } - Chain.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitChain(this, context); - }; - return Chain; -}(AST)); -var Conditional = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Conditional, _super); - function Conditional(span, condition, trueExp, falseExp) { - var _this = _super.call(this, span) || this; - _this.condition = condition; - _this.trueExp = trueExp; - _this.falseExp = falseExp; - return _this; - } - Conditional.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitConditional(this, context); - }; - return Conditional; -}(AST)); -var PropertyRead = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(PropertyRead, _super); - function PropertyRead(span, receiver, name) { - var _this = _super.call(this, span) || this; - _this.receiver = receiver; - _this.name = name; - return _this; - } - PropertyRead.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitPropertyRead(this, context); - }; - return PropertyRead; -}(AST)); -var PropertyWrite = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(PropertyWrite, _super); - function PropertyWrite(span, receiver, name, value) { - var _this = _super.call(this, span) || this; - _this.receiver = receiver; - _this.name = name; - _this.value = value; - return _this; - } - PropertyWrite.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitPropertyWrite(this, context); - }; - return PropertyWrite; -}(AST)); -var SafePropertyRead = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(SafePropertyRead, _super); - function SafePropertyRead(span, receiver, name) { - var _this = _super.call(this, span) || this; - _this.receiver = receiver; - _this.name = name; - return _this; - } - SafePropertyRead.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitSafePropertyRead(this, context); - }; - return SafePropertyRead; -}(AST)); -var KeyedRead = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(KeyedRead, _super); - function KeyedRead(span, obj, key) { - var _this = _super.call(this, span) || this; - _this.obj = obj; - _this.key = key; - return _this; - } - KeyedRead.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitKeyedRead(this, context); - }; - return KeyedRead; -}(AST)); -var KeyedWrite = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(KeyedWrite, _super); - function KeyedWrite(span, obj, key, value) { - var _this = _super.call(this, span) || this; - _this.obj = obj; - _this.key = key; - _this.value = value; - return _this; - } - KeyedWrite.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitKeyedWrite(this, context); - }; - return KeyedWrite; -}(AST)); -var BindingPipe = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(BindingPipe, _super); - function BindingPipe(span, exp, name, args) { - var _this = _super.call(this, span) || this; - _this.exp = exp; - _this.name = name; - _this.args = args; - return _this; - } - BindingPipe.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitPipe(this, context); - }; - return BindingPipe; -}(AST)); -var LiteralPrimitive = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralPrimitive, _super); - function LiteralPrimitive(span, value) { - var _this = _super.call(this, span) || this; - _this.value = value; - return _this; - } - LiteralPrimitive.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitLiteralPrimitive(this, context); - }; - return LiteralPrimitive; -}(AST)); -var LiteralArray = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralArray, _super); - function LiteralArray(span, expressions) { - var _this = _super.call(this, span) || this; - _this.expressions = expressions; - return _this; - } - LiteralArray.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitLiteralArray(this, context); - }; - return LiteralArray; -}(AST)); -var LiteralMap = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(LiteralMap, _super); - function LiteralMap(span, keys, values) { - var _this = _super.call(this, span) || this; - _this.keys = keys; - _this.values = values; - return _this; - } - LiteralMap.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitLiteralMap(this, context); - }; - return LiteralMap; -}(AST)); -var Interpolation = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Interpolation, _super); - function Interpolation(span, strings, expressions) { - var _this = _super.call(this, span) || this; - _this.strings = strings; - _this.expressions = expressions; - return _this; - } - Interpolation.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitInterpolation(this, context); - }; - return Interpolation; -}(AST)); -var Binary = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(Binary, _super); - function Binary(span, operation, left, right) { - var _this = _super.call(this, span) || this; - _this.operation = operation; - _this.left = left; - _this.right = right; - return _this; - } - Binary.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitBinary(this, context); - }; - return Binary; -}(AST)); -var PrefixNot = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(PrefixNot, _super); - function PrefixNot(span, expression) { - var _this = _super.call(this, span) || this; - _this.expression = expression; - return _this; - } - PrefixNot.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitPrefixNot(this, context); - }; - return PrefixNot; -}(AST)); -var NonNullAssert = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(NonNullAssert, _super); - function NonNullAssert(span, expression) { - var _this = _super.call(this, span) || this; - _this.expression = expression; - return _this; - } - NonNullAssert.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitNonNullAssert(this, context); - }; - return NonNullAssert; -}(AST)); -var MethodCall = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(MethodCall, _super); - function MethodCall(span, receiver, name, args) { - var _this = _super.call(this, span) || this; - _this.receiver = receiver; - _this.name = name; - _this.args = args; - return _this; - } - MethodCall.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitMethodCall(this, context); - }; - return MethodCall; -}(AST)); -var SafeMethodCall = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(SafeMethodCall, _super); - function SafeMethodCall(span, receiver, name, args) { - var _this = _super.call(this, span) || this; - _this.receiver = receiver; - _this.name = name; - _this.args = args; - return _this; - } - SafeMethodCall.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitSafeMethodCall(this, context); - }; - return SafeMethodCall; -}(AST)); -var FunctionCall = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(FunctionCall, _super); - function FunctionCall(span, target, args) { - var _this = _super.call(this, span) || this; - _this.target = target; - _this.args = args; - return _this; - } - FunctionCall.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - return visitor.visitFunctionCall(this, context); - }; - return FunctionCall; -}(AST)); -/** - * Records the absolute position of a text span in a source file, where `start` and `end` are the - * starting and ending byte offsets, respectively, of the text span in a source file. - */ -var AbsoluteSourceSpan = /** @class */ (function () { - function AbsoluteSourceSpan(start, end) { - this.start = start; - this.end = end; - } - return AbsoluteSourceSpan; -}()); -var ASTWithSource = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ASTWithSource, _super); - function ASTWithSource(ast, source, location, absoluteOffset, errors) { - var _this = _super.call(this, new ParseSpan(0, source == null ? 0 : source.length)) || this; - _this.ast = ast; - _this.source = source; - _this.location = location; - _this.errors = errors; - _this.sourceSpan = new AbsoluteSourceSpan(absoluteOffset, absoluteOffset + _this.span.end); - return _this; - } - ASTWithSource.prototype.visit = function (visitor, context) { - if (context === void 0) { context = null; } - if (visitor.visitASTWithSource) { - return visitor.visitASTWithSource(this, context); - } - return this.ast.visit(visitor, context); - }; - ASTWithSource.prototype.toString = function () { return this.source + " in " + this.location; }; - return ASTWithSource; -}(AST)); -var TemplateBinding = /** @class */ (function () { - function TemplateBinding(span, key, keyIsVar, name, expression) { - this.span = span; - this.key = key; - this.keyIsVar = keyIsVar; - this.name = name; - this.expression = expression; - } - return TemplateBinding; -}()); -var NullAstVisitor = /** @class */ (function () { - function NullAstVisitor() { - } - NullAstVisitor.prototype.visitBinary = function (ast, context) { }; - NullAstVisitor.prototype.visitChain = function (ast, context) { }; - NullAstVisitor.prototype.visitConditional = function (ast, context) { }; - NullAstVisitor.prototype.visitFunctionCall = function (ast, context) { }; - NullAstVisitor.prototype.visitImplicitReceiver = function (ast, context) { }; - NullAstVisitor.prototype.visitInterpolation = function (ast, context) { }; - NullAstVisitor.prototype.visitKeyedRead = function (ast, context) { }; - NullAstVisitor.prototype.visitKeyedWrite = function (ast, context) { }; - NullAstVisitor.prototype.visitLiteralArray = function (ast, context) { }; - NullAstVisitor.prototype.visitLiteralMap = function (ast, context) { }; - NullAstVisitor.prototype.visitLiteralPrimitive = function (ast, context) { }; - NullAstVisitor.prototype.visitMethodCall = function (ast, context) { }; - NullAstVisitor.prototype.visitPipe = function (ast, context) { }; - NullAstVisitor.prototype.visitPrefixNot = function (ast, context) { }; - NullAstVisitor.prototype.visitNonNullAssert = function (ast, context) { }; - NullAstVisitor.prototype.visitPropertyRead = function (ast, context) { }; - NullAstVisitor.prototype.visitPropertyWrite = function (ast, context) { }; - NullAstVisitor.prototype.visitQuote = function (ast, context) { }; - NullAstVisitor.prototype.visitSafeMethodCall = function (ast, context) { }; - NullAstVisitor.prototype.visitSafePropertyRead = function (ast, context) { }; - return NullAstVisitor; -}()); -var RecursiveAstVisitor$1 = /** @class */ (function () { - function RecursiveAstVisitor() { - } - RecursiveAstVisitor.prototype.visitBinary = function (ast, context) { - ast.left.visit(this, context); - ast.right.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitChain = function (ast, context) { return this.visitAll(ast.expressions, context); }; - RecursiveAstVisitor.prototype.visitConditional = function (ast, context) { - ast.condition.visit(this, context); - ast.trueExp.visit(this, context); - ast.falseExp.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitPipe = function (ast, context) { - ast.exp.visit(this, context); - this.visitAll(ast.args, context); - return null; - }; - RecursiveAstVisitor.prototype.visitFunctionCall = function (ast, context) { - ast.target.visit(this, context); - this.visitAll(ast.args, context); - return null; - }; - RecursiveAstVisitor.prototype.visitImplicitReceiver = function (ast, context) { return null; }; - RecursiveAstVisitor.prototype.visitInterpolation = function (ast, context) { - return this.visitAll(ast.expressions, context); - }; - RecursiveAstVisitor.prototype.visitKeyedRead = function (ast, context) { - ast.obj.visit(this, context); - ast.key.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitKeyedWrite = function (ast, context) { - ast.obj.visit(this, context); - ast.key.visit(this, context); - ast.value.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitLiteralArray = function (ast, context) { - return this.visitAll(ast.expressions, context); - }; - RecursiveAstVisitor.prototype.visitLiteralMap = function (ast, context) { return this.visitAll(ast.values, context); }; - RecursiveAstVisitor.prototype.visitLiteralPrimitive = function (ast, context) { return null; }; - RecursiveAstVisitor.prototype.visitMethodCall = function (ast, context) { - ast.receiver.visit(this, context); - return this.visitAll(ast.args, context); - }; - RecursiveAstVisitor.prototype.visitPrefixNot = function (ast, context) { - ast.expression.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitNonNullAssert = function (ast, context) { - ast.expression.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitPropertyRead = function (ast, context) { - ast.receiver.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitPropertyWrite = function (ast, context) { - ast.receiver.visit(this, context); - ast.value.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitSafePropertyRead = function (ast, context) { - ast.receiver.visit(this, context); - return null; - }; - RecursiveAstVisitor.prototype.visitSafeMethodCall = function (ast, context) { - ast.receiver.visit(this, context); - return this.visitAll(ast.args, context); - }; - RecursiveAstVisitor.prototype.visitAll = function (asts, context) { - var _this = this; - asts.forEach(function (ast) { return ast.visit(_this, context); }); - return null; - }; - RecursiveAstVisitor.prototype.visitQuote = function (ast, context) { return null; }; - return RecursiveAstVisitor; -}()); -var AstTransformer$1 = /** @class */ (function () { - function AstTransformer() { - } - AstTransformer.prototype.visitImplicitReceiver = function (ast, context) { return ast; }; - AstTransformer.prototype.visitInterpolation = function (ast, context) { - return new Interpolation(ast.span, ast.strings, this.visitAll(ast.expressions)); - }; - AstTransformer.prototype.visitLiteralPrimitive = function (ast, context) { - return new LiteralPrimitive(ast.span, ast.value); - }; - AstTransformer.prototype.visitPropertyRead = function (ast, context) { - return new PropertyRead(ast.span, ast.receiver.visit(this), ast.name); - }; - AstTransformer.prototype.visitPropertyWrite = function (ast, context) { - return new PropertyWrite(ast.span, ast.receiver.visit(this), ast.name, ast.value.visit(this)); - }; - AstTransformer.prototype.visitSafePropertyRead = function (ast, context) { - return new SafePropertyRead(ast.span, ast.receiver.visit(this), ast.name); - }; - AstTransformer.prototype.visitMethodCall = function (ast, context) { - return new MethodCall(ast.span, ast.receiver.visit(this), ast.name, this.visitAll(ast.args)); - }; - AstTransformer.prototype.visitSafeMethodCall = function (ast, context) { - return new SafeMethodCall(ast.span, ast.receiver.visit(this), ast.name, this.visitAll(ast.args)); - }; - AstTransformer.prototype.visitFunctionCall = function (ast, context) { - return new FunctionCall(ast.span, ast.target.visit(this), this.visitAll(ast.args)); - }; - AstTransformer.prototype.visitLiteralArray = function (ast, context) { - return new LiteralArray(ast.span, this.visitAll(ast.expressions)); - }; - AstTransformer.prototype.visitLiteralMap = function (ast, context) { - return new LiteralMap(ast.span, ast.keys, this.visitAll(ast.values)); - }; - AstTransformer.prototype.visitBinary = function (ast, context) { - return new Binary(ast.span, ast.operation, ast.left.visit(this), ast.right.visit(this)); - }; - AstTransformer.prototype.visitPrefixNot = function (ast, context) { - return new PrefixNot(ast.span, ast.expression.visit(this)); - }; - AstTransformer.prototype.visitNonNullAssert = function (ast, context) { - return new NonNullAssert(ast.span, ast.expression.visit(this)); - }; - AstTransformer.prototype.visitConditional = function (ast, context) { - return new Conditional(ast.span, ast.condition.visit(this), ast.trueExp.visit(this), ast.falseExp.visit(this)); - }; - AstTransformer.prototype.visitPipe = function (ast, context) { - return new BindingPipe(ast.span, ast.exp.visit(this), ast.name, this.visitAll(ast.args)); - }; - AstTransformer.prototype.visitKeyedRead = function (ast, context) { - return new KeyedRead(ast.span, ast.obj.visit(this), ast.key.visit(this)); - }; - AstTransformer.prototype.visitKeyedWrite = function (ast, context) { - return new KeyedWrite(ast.span, ast.obj.visit(this), ast.key.visit(this), ast.value.visit(this)); - }; - AstTransformer.prototype.visitAll = function (asts) { - var res = new Array(asts.length); - for (var i = 0; i < asts.length; ++i) { - res[i] = asts[i].visit(this); - } - return res; - }; - AstTransformer.prototype.visitChain = function (ast, context) { - return new Chain(ast.span, this.visitAll(ast.expressions)); - }; - AstTransformer.prototype.visitQuote = function (ast, context) { - return new Quote(ast.span, ast.prefix, ast.uninterpretedExpression, ast.location); - }; - return AstTransformer; -}()); -// A transformer that only creates new nodes if the transformer makes a change or -// a change is made a child node. -var AstMemoryEfficientTransformer = /** @class */ (function () { - function AstMemoryEfficientTransformer() { - } - AstMemoryEfficientTransformer.prototype.visitImplicitReceiver = function (ast, context) { return ast; }; - AstMemoryEfficientTransformer.prototype.visitInterpolation = function (ast, context) { - var expressions = this.visitAll(ast.expressions); - if (expressions !== ast.expressions) - return new Interpolation(ast.span, ast.strings, expressions); - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitLiteralPrimitive = function (ast, context) { return ast; }; - AstMemoryEfficientTransformer.prototype.visitPropertyRead = function (ast, context) { - var receiver = ast.receiver.visit(this); - if (receiver !== ast.receiver) { - return new PropertyRead(ast.span, receiver, ast.name); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitPropertyWrite = function (ast, context) { - var receiver = ast.receiver.visit(this); - var value = ast.value.visit(this); - if (receiver !== ast.receiver || value !== ast.value) { - return new PropertyWrite(ast.span, receiver, ast.name, value); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitSafePropertyRead = function (ast, context) { - var receiver = ast.receiver.visit(this); - if (receiver !== ast.receiver) { - return new SafePropertyRead(ast.span, receiver, ast.name); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitMethodCall = function (ast, context) { - var receiver = ast.receiver.visit(this); - var args = this.visitAll(ast.args); - if (receiver !== ast.receiver || args !== ast.args) { - return new MethodCall(ast.span, receiver, ast.name, args); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitSafeMethodCall = function (ast, context) { - var receiver = ast.receiver.visit(this); - var args = this.visitAll(ast.args); - if (receiver !== ast.receiver || args !== ast.args) { - return new SafeMethodCall(ast.span, receiver, ast.name, args); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitFunctionCall = function (ast, context) { - var target = ast.target && ast.target.visit(this); - var args = this.visitAll(ast.args); - if (target !== ast.target || args !== ast.args) { - return new FunctionCall(ast.span, target, args); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitLiteralArray = function (ast, context) { - var expressions = this.visitAll(ast.expressions); - if (expressions !== ast.expressions) { - return new LiteralArray(ast.span, expressions); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitLiteralMap = function (ast, context) { - var values = this.visitAll(ast.values); - if (values !== ast.values) { - return new LiteralMap(ast.span, ast.keys, values); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitBinary = function (ast, context) { - var left = ast.left.visit(this); - var right = ast.right.visit(this); - if (left !== ast.left || right !== ast.right) { - return new Binary(ast.span, ast.operation, left, right); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitPrefixNot = function (ast, context) { - var expression = ast.expression.visit(this); - if (expression !== ast.expression) { - return new PrefixNot(ast.span, expression); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitNonNullAssert = function (ast, context) { - var expression = ast.expression.visit(this); - if (expression !== ast.expression) { - return new NonNullAssert(ast.span, expression); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitConditional = function (ast, context) { - var condition = ast.condition.visit(this); - var trueExp = ast.trueExp.visit(this); - var falseExp = ast.falseExp.visit(this); - if (condition !== ast.condition || trueExp !== ast.trueExp || falseExp !== ast.falseExp) { - return new Conditional(ast.span, condition, trueExp, falseExp); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitPipe = function (ast, context) { - var exp = ast.exp.visit(this); - var args = this.visitAll(ast.args); - if (exp !== ast.exp || args !== ast.args) { - return new BindingPipe(ast.span, exp, ast.name, args); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitKeyedRead = function (ast, context) { - var obj = ast.obj.visit(this); - var key = ast.key.visit(this); - if (obj !== ast.obj || key !== ast.key) { - return new KeyedRead(ast.span, obj, key); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitKeyedWrite = function (ast, context) { - var obj = ast.obj.visit(this); - var key = ast.key.visit(this); - var value = ast.value.visit(this); - if (obj !== ast.obj || key !== ast.key || value !== ast.value) { - return new KeyedWrite(ast.span, obj, key, value); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitAll = function (asts) { - var res = new Array(asts.length); - var modified = false; - for (var i = 0; i < asts.length; ++i) { - var original = asts[i]; - var value = original.visit(this); - res[i] = value; - modified = modified || value !== original; - } - return modified ? res : asts; - }; - AstMemoryEfficientTransformer.prototype.visitChain = function (ast, context) { - var expressions = this.visitAll(ast.expressions); - if (expressions !== ast.expressions) { - return new Chain(ast.span, expressions); - } - return ast; - }; - AstMemoryEfficientTransformer.prototype.visitQuote = function (ast, context) { return ast; }; - return AstMemoryEfficientTransformer; -}()); -function visitAstChildren(ast, visitor, context) { - function visit(ast) { - visitor.visit && visitor.visit(ast, context) || ast.visit(visitor, context); - } - function visitAll(asts) { asts.forEach(visit); } - ast.visit({ - visitBinary: function (ast) { - visit(ast.left); - visit(ast.right); - }, - visitChain: function (ast) { visitAll(ast.expressions); }, - visitConditional: function (ast) { - visit(ast.condition); - visit(ast.trueExp); - visit(ast.falseExp); - }, - visitFunctionCall: function (ast) { - if (ast.target) { - visit(ast.target); - } - visitAll(ast.args); - }, - visitImplicitReceiver: function (ast) { }, - visitInterpolation: function (ast) { visitAll(ast.expressions); }, - visitKeyedRead: function (ast) { - visit(ast.obj); - visit(ast.key); - }, - visitKeyedWrite: function (ast) { - visit(ast.obj); - visit(ast.key); - visit(ast.obj); - }, - visitLiteralArray: function (ast) { visitAll(ast.expressions); }, - visitLiteralMap: function (ast) { }, - visitLiteralPrimitive: function (ast) { }, - visitMethodCall: function (ast) { - visit(ast.receiver); - visitAll(ast.args); - }, - visitPipe: function (ast) { - visit(ast.exp); - visitAll(ast.args); - }, - visitPrefixNot: function (ast) { visit(ast.expression); }, - visitNonNullAssert: function (ast) { visit(ast.expression); }, - visitPropertyRead: function (ast) { visit(ast.receiver); }, - visitPropertyWrite: function (ast) { - visit(ast.receiver); - visit(ast.value); - }, - visitQuote: function (ast) { }, - visitSafeMethodCall: function (ast) { - visit(ast.receiver); - visitAll(ast.args); - }, - visitSafePropertyRead: function (ast) { visit(ast.receiver); }, - }); -} -// Bindings -var ParsedProperty = /** @class */ (function () { - function ParsedProperty(name, expression, type, sourceSpan, valueSpan) { - this.name = name; - this.expression = expression; - this.type = type; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - this.isLiteral = this.type === ParsedPropertyType.LITERAL_ATTR; - this.isAnimation = this.type === ParsedPropertyType.ANIMATION; - } - return ParsedProperty; -}()); -var ParsedPropertyType; -(function (ParsedPropertyType) { - ParsedPropertyType[ParsedPropertyType["DEFAULT"] = 0] = "DEFAULT"; - ParsedPropertyType[ParsedPropertyType["LITERAL_ATTR"] = 1] = "LITERAL_ATTR"; - ParsedPropertyType[ParsedPropertyType["ANIMATION"] = 2] = "ANIMATION"; -})(ParsedPropertyType || (ParsedPropertyType = {})); -var ParsedEvent = /** @class */ (function () { - // Regular events have a target - // Animation events have a phase - function ParsedEvent(name, targetOrPhase, type, handler, sourceSpan, handlerSpan) { - this.name = name; - this.targetOrPhase = targetOrPhase; - this.type = type; - this.handler = handler; - this.sourceSpan = sourceSpan; - this.handlerSpan = handlerSpan; - } - return ParsedEvent; -}()); -var ParsedVariable = /** @class */ (function () { - function ParsedVariable(name, value, sourceSpan) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - } - return ParsedVariable; -}()); -var BoundElementProperty = /** @class */ (function () { - function BoundElementProperty(name, type, securityContext, value, unit, sourceSpan, valueSpan) { - this.name = name; - this.type = type; - this.securityContext = securityContext; - this.value = value; - this.unit = unit; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - } - return BoundElementProperty; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var EventHandlerVars = /** @class */ (function () { - function EventHandlerVars() { - } - EventHandlerVars.event = variable('$event'); - return EventHandlerVars; -}()); -var ConvertActionBindingResult = /** @class */ (function () { - function ConvertActionBindingResult( - /** - * Render2 compatible statements, - */ - stmts, - /** - * Variable name used with render2 compatible statements. - */ - allowDefault) { - this.stmts = stmts; - this.allowDefault = allowDefault; - /** - * This is bit of a hack. It converts statements which render2 expects to statements which are - * expected by render3. - * - * Example: `
    ` will generate: - * - * Render3: - * ``` - * const pd_b:any = ((ctx.doSomething($event)) !== false); - * return pd_b; - * ``` - * - * but render2 expects: - * ``` - * return ctx.doSomething($event); - * ``` - */ - // TODO(misko): remove this hack once we no longer support ViewEngine. - this.render3Stmts = stmts.map(function (statement) { - if (statement instanceof DeclareVarStmt && statement.name == allowDefault.name && - statement.value instanceof BinaryOperatorExpr) { - var lhs = statement.value.lhs; - return new ReturnStatement(lhs.value); - } - return statement; - }); - } - return ConvertActionBindingResult; -}()); -/** - * Converts the given expression AST into an executable output AST, assuming the expression is - * used in an action binding (e.g. an event handler). - */ -function convertActionBinding(localResolver, implicitReceiver, action, bindingId, interpolationFunction, baseSourceSpan) { - if (!localResolver) { - localResolver = new DefaultLocalResolver(); - } - var actionWithoutBuiltins = convertPropertyBindingBuiltins({ - createLiteralArrayConverter: function (argCount) { - // Note: no caching for literal arrays in actions. - return function (args) { return literalArr(args); }; - }, - createLiteralMapConverter: function (keys) { - // Note: no caching for literal maps in actions. - return function (values) { - var entries = keys.map(function (k, i) { return ({ - key: k.key, - value: values[i], - quoted: k.quoted, - }); }); - return literalMap(entries); - }; - }, - createPipeConverter: function (name) { - throw new Error("Illegal State: Actions are not allowed to contain pipes. Pipe: " + name); - } - }, action); - var visitor = new _AstToIrVisitor(localResolver, implicitReceiver, bindingId, interpolationFunction, baseSourceSpan); - var actionStmts = []; - flattenStatements(actionWithoutBuiltins.visit(visitor, _Mode.Statement), actionStmts); - prependTemporaryDecls(visitor.temporaryCount, bindingId, actionStmts); - if (visitor.usesImplicitReceiver) { - localResolver.notifyImplicitReceiverUse(); - } - var lastIndex = actionStmts.length - 1; - var preventDefaultVar = null; - if (lastIndex >= 0) { - var lastStatement = actionStmts[lastIndex]; - var returnExpr = convertStmtIntoExpression(lastStatement); - if (returnExpr) { - // Note: We need to cast the result of the method call to dynamic, - // as it might be a void method! - preventDefaultVar = createPreventDefaultVar(bindingId); - actionStmts[lastIndex] = - preventDefaultVar.set(returnExpr.cast(DYNAMIC_TYPE).notIdentical(literal(false))) - .toDeclStmt(null, [StmtModifier.Final]); - } - } - return new ConvertActionBindingResult(actionStmts, preventDefaultVar); -} -function convertPropertyBindingBuiltins(converterFactory, ast) { - return convertBuiltins(converterFactory, ast); -} -var ConvertPropertyBindingResult = /** @class */ (function () { - function ConvertPropertyBindingResult(stmts, currValExpr) { - this.stmts = stmts; - this.currValExpr = currValExpr; - } - return ConvertPropertyBindingResult; -}()); -var BindingForm; -(function (BindingForm) { - // The general form of binding expression, supports all expressions. - BindingForm[BindingForm["General"] = 0] = "General"; - // Try to generate a simple binding (no temporaries or statements) - // otherwise generate a general binding - BindingForm[BindingForm["TrySimple"] = 1] = "TrySimple"; -})(BindingForm || (BindingForm = {})); -/** - * Converts the given expression AST into an executable output AST, assuming the expression - * is used in property binding. The expression has to be preprocessed via - * `convertPropertyBindingBuiltins`. - */ -function convertPropertyBinding(localResolver, implicitReceiver, expressionWithoutBuiltins, bindingId, form, interpolationFunction) { - if (!localResolver) { - localResolver = new DefaultLocalResolver(); - } - var currValExpr = createCurrValueExpr(bindingId); - var visitor = new _AstToIrVisitor(localResolver, implicitReceiver, bindingId, interpolationFunction); - var outputExpr = expressionWithoutBuiltins.visit(visitor, _Mode.Expression); - var stmts = getStatementsFromVisitor(visitor, bindingId); - if (visitor.usesImplicitReceiver) { - localResolver.notifyImplicitReceiverUse(); - } - if (visitor.temporaryCount === 0 && form == BindingForm.TrySimple) { - return new ConvertPropertyBindingResult([], outputExpr); - } - stmts.push(currValExpr.set(outputExpr).toDeclStmt(DYNAMIC_TYPE, [StmtModifier.Final])); - return new ConvertPropertyBindingResult(stmts, currValExpr); -} -/** - * Given some expression, such as a binding or interpolation expression, and a context expression to - * look values up on, visit each facet of the given expression resolving values from the context - * expression such that a list of arguments can be derived from the found values that can be used as - * arguments to an external update instruction. - * - * @param localResolver The resolver to use to look up expressions by name appropriately - * @param contextVariableExpression The expression representing the context variable used to create - * the final argument expressions - * @param expressionWithArgumentsToExtract The expression to visit to figure out what values need to - * be resolved and what arguments list to build. - * @param bindingId A name prefix used to create temporary variable names if they're needed for the - * arguments generated - * @returns An array of expressions that can be passed as arguments to instruction expressions like - * `o.importExpr(R3.propertyInterpolate).callFn(result)` - */ -function convertUpdateArguments(localResolver, contextVariableExpression, expressionWithArgumentsToExtract, bindingId) { - var visitor = new _AstToIrVisitor(localResolver, contextVariableExpression, bindingId, undefined); - var outputExpr = expressionWithArgumentsToExtract.visit(visitor, _Mode.Expression); - if (visitor.usesImplicitReceiver) { - localResolver.notifyImplicitReceiverUse(); - } - var stmts = getStatementsFromVisitor(visitor, bindingId); - // Removing the first argument, because it was a length for ViewEngine, not Ivy. - var args = outputExpr.args.slice(1); - if (expressionWithArgumentsToExtract instanceof Interpolation) { - // If we're dealing with an interpolation of 1 value with an empty prefix and suffix, reduce the - // args returned to just the value, because we're going to pass it to a special instruction. - var strings = expressionWithArgumentsToExtract.strings; - if (args.length === 3 && strings[0] === '' && strings[1] === '') { - // Single argument interpolate instructions. - args = [args[1]]; - } - else if (args.length >= 19) { - // 19 or more arguments must be passed to the `interpolateV`-style instructions, which accept - // an array of arguments - args = [literalArr(args)]; - } - } - return { stmts: stmts, args: args }; -} -function getStatementsFromVisitor(visitor, bindingId) { - var stmts = []; - for (var i = 0; i < visitor.temporaryCount; i++) { - stmts.push(temporaryDeclaration(bindingId, i)); - } - return stmts; -} -function convertBuiltins(converterFactory, ast) { - var visitor = new _BuiltinAstConverter(converterFactory); - return ast.visit(visitor); -} -function temporaryName(bindingId, temporaryNumber) { - return "tmp_" + bindingId + "_" + temporaryNumber; -} -function temporaryDeclaration(bindingId, temporaryNumber) { - return new DeclareVarStmt(temporaryName(bindingId, temporaryNumber), NULL_EXPR); -} -function prependTemporaryDecls(temporaryCount, bindingId, statements) { - for (var i = temporaryCount - 1; i >= 0; i--) { - statements.unshift(temporaryDeclaration(bindingId, i)); - } -} -var _Mode; -(function (_Mode) { - _Mode[_Mode["Statement"] = 0] = "Statement"; - _Mode[_Mode["Expression"] = 1] = "Expression"; -})(_Mode || (_Mode = {})); -function ensureStatementMode(mode, ast) { - if (mode !== _Mode.Statement) { - throw new Error("Expected a statement, but saw " + ast); - } -} -function ensureExpressionMode(mode, ast) { - if (mode !== _Mode.Expression) { - throw new Error("Expected an expression, but saw " + ast); - } -} -function convertToStatementIfNeeded(mode, expr) { - if (mode === _Mode.Statement) { - return expr.toStmt(); - } - else { - return expr; - } -} -var _BuiltinAstConverter = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(_BuiltinAstConverter, _super); - function _BuiltinAstConverter(_converterFactory) { - var _this = _super.call(this) || this; - _this._converterFactory = _converterFactory; - return _this; - } - _BuiltinAstConverter.prototype.visitPipe = function (ast, context) { - var _this = this; - var args = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([ast.exp], ast.args).map(function (ast) { return ast.visit(_this, context); }); - return new BuiltinFunctionCall(ast.span, args, this._converterFactory.createPipeConverter(ast.name, args.length)); - }; - _BuiltinAstConverter.prototype.visitLiteralArray = function (ast, context) { - var _this = this; - var args = ast.expressions.map(function (ast) { return ast.visit(_this, context); }); - return new BuiltinFunctionCall(ast.span, args, this._converterFactory.createLiteralArrayConverter(ast.expressions.length)); - }; - _BuiltinAstConverter.prototype.visitLiteralMap = function (ast, context) { - var _this = this; - var args = ast.values.map(function (ast) { return ast.visit(_this, context); }); - return new BuiltinFunctionCall(ast.span, args, this._converterFactory.createLiteralMapConverter(ast.keys)); - }; - return _BuiltinAstConverter; -}(AstTransformer$1)); -var _AstToIrVisitor = /** @class */ (function () { - function _AstToIrVisitor(_localResolver, _implicitReceiver, bindingId, interpolationFunction, baseSourceSpan) { - this._localResolver = _localResolver; - this._implicitReceiver = _implicitReceiver; - this.bindingId = bindingId; - this.interpolationFunction = interpolationFunction; - this.baseSourceSpan = baseSourceSpan; - this._nodeMap = new Map(); - this._resultMap = new Map(); - this._currentTemporary = 0; - this.temporaryCount = 0; - this.usesImplicitReceiver = false; - } - _AstToIrVisitor.prototype.visitBinary = function (ast, mode) { - var op; - switch (ast.operation) { - case '+': - op = BinaryOperator.Plus; - break; - case '-': - op = BinaryOperator.Minus; - break; - case '*': - op = BinaryOperator.Multiply; - break; - case '/': - op = BinaryOperator.Divide; - break; - case '%': - op = BinaryOperator.Modulo; - break; - case '&&': - op = BinaryOperator.And; - break; - case '||': - op = BinaryOperator.Or; - break; - case '==': - op = BinaryOperator.Equals; - break; - case '!=': - op = BinaryOperator.NotEquals; - break; - case '===': - op = BinaryOperator.Identical; - break; - case '!==': - op = BinaryOperator.NotIdentical; - break; - case '<': - op = BinaryOperator.Lower; - break; - case '>': - op = BinaryOperator.Bigger; - break; - case '<=': - op = BinaryOperator.LowerEquals; - break; - case '>=': - op = BinaryOperator.BiggerEquals; - break; - default: - throw new Error("Unsupported operation " + ast.operation); - } - return convertToStatementIfNeeded(mode, new BinaryOperatorExpr(op, this._visit(ast.left, _Mode.Expression), this._visit(ast.right, _Mode.Expression), undefined, this.convertSourceSpan(ast.span))); - }; - _AstToIrVisitor.prototype.visitChain = function (ast, mode) { - ensureStatementMode(mode, ast); - return this.visitAll(ast.expressions, mode); - }; - _AstToIrVisitor.prototype.visitConditional = function (ast, mode) { - var value = this._visit(ast.condition, _Mode.Expression); - return convertToStatementIfNeeded(mode, value.conditional(this._visit(ast.trueExp, _Mode.Expression), this._visit(ast.falseExp, _Mode.Expression), this.convertSourceSpan(ast.span))); - }; - _AstToIrVisitor.prototype.visitPipe = function (ast, mode) { - throw new Error("Illegal state: Pipes should have been converted into functions. Pipe: " + ast.name); - }; - _AstToIrVisitor.prototype.visitFunctionCall = function (ast, mode) { - var convertedArgs = this.visitAll(ast.args, _Mode.Expression); - var fnResult; - if (ast instanceof BuiltinFunctionCall) { - fnResult = ast.converter(convertedArgs); - } - else { - fnResult = this._visit(ast.target, _Mode.Expression) - .callFn(convertedArgs, this.convertSourceSpan(ast.span)); - } - return convertToStatementIfNeeded(mode, fnResult); - }; - _AstToIrVisitor.prototype.visitImplicitReceiver = function (ast, mode) { - ensureExpressionMode(mode, ast); - this.usesImplicitReceiver = true; - return this._implicitReceiver; - }; - _AstToIrVisitor.prototype.visitInterpolation = function (ast, mode) { - ensureExpressionMode(mode, ast); - var args = [literal(ast.expressions.length)]; - for (var i = 0; i < ast.strings.length - 1; i++) { - args.push(literal(ast.strings[i])); - args.push(this._visit(ast.expressions[i], _Mode.Expression)); - } - args.push(literal(ast.strings[ast.strings.length - 1])); - if (this.interpolationFunction) { - return this.interpolationFunction(args); - } - return ast.expressions.length <= 9 ? - importExpr(Identifiers.inlineInterpolate).callFn(args) : - importExpr(Identifiers.interpolate).callFn([ - args[0], literalArr(args.slice(1), undefined, this.convertSourceSpan(ast.span)) - ]); - }; - _AstToIrVisitor.prototype.visitKeyedRead = function (ast, mode) { - var leftMostSafe = this.leftMostSafeNode(ast); - if (leftMostSafe) { - return this.convertSafeAccess(ast, leftMostSafe, mode); - } - else { - return convertToStatementIfNeeded(mode, this._visit(ast.obj, _Mode.Expression).key(this._visit(ast.key, _Mode.Expression))); - } - }; - _AstToIrVisitor.prototype.visitKeyedWrite = function (ast, mode) { - var obj = this._visit(ast.obj, _Mode.Expression); - var key = this._visit(ast.key, _Mode.Expression); - var value = this._visit(ast.value, _Mode.Expression); - return convertToStatementIfNeeded(mode, obj.key(key).set(value)); - }; - _AstToIrVisitor.prototype.visitLiteralArray = function (ast, mode) { - throw new Error("Illegal State: literal arrays should have been converted into functions"); - }; - _AstToIrVisitor.prototype.visitLiteralMap = function (ast, mode) { - throw new Error("Illegal State: literal maps should have been converted into functions"); - }; - _AstToIrVisitor.prototype.visitLiteralPrimitive = function (ast, mode) { - // For literal values of null, undefined, true, or false allow type interference - // to infer the type. - var type = ast.value === null || ast.value === undefined || ast.value === true || ast.value === true ? - INFERRED_TYPE : - undefined; - return convertToStatementIfNeeded(mode, literal(ast.value, type, this.convertSourceSpan(ast.span))); - }; - _AstToIrVisitor.prototype._getLocal = function (name) { return this._localResolver.getLocal(name); }; - _AstToIrVisitor.prototype.visitMethodCall = function (ast, mode) { - if (ast.receiver instanceof ImplicitReceiver && ast.name == '$any') { - var args = this.visitAll(ast.args, _Mode.Expression); - if (args.length != 1) { - throw new Error("Invalid call to $any, expected 1 argument but received " + (args.length || 'none')); - } - return args[0].cast(DYNAMIC_TYPE, this.convertSourceSpan(ast.span)); - } - var leftMostSafe = this.leftMostSafeNode(ast); - if (leftMostSafe) { - return this.convertSafeAccess(ast, leftMostSafe, mode); - } - else { - var args = this.visitAll(ast.args, _Mode.Expression); - var prevUsesImplicitReceiver = this.usesImplicitReceiver; - var result = null; - var receiver = this._visit(ast.receiver, _Mode.Expression); - if (receiver === this._implicitReceiver) { - var varExpr = this._getLocal(ast.name); - if (varExpr) { - // Restore the previous "usesImplicitReceiver" state since the implicit - // receiver has been replaced with a resolved local expression. - this.usesImplicitReceiver = prevUsesImplicitReceiver; - result = varExpr.callFn(args); - } - } - if (result == null) { - result = receiver.callMethod(ast.name, args, this.convertSourceSpan(ast.span)); - } - return convertToStatementIfNeeded(mode, result); - } - }; - _AstToIrVisitor.prototype.visitPrefixNot = function (ast, mode) { - return convertToStatementIfNeeded(mode, not(this._visit(ast.expression, _Mode.Expression))); - }; - _AstToIrVisitor.prototype.visitNonNullAssert = function (ast, mode) { - return convertToStatementIfNeeded(mode, assertNotNull(this._visit(ast.expression, _Mode.Expression))); - }; - _AstToIrVisitor.prototype.visitPropertyRead = function (ast, mode) { - var leftMostSafe = this.leftMostSafeNode(ast); - if (leftMostSafe) { - return this.convertSafeAccess(ast, leftMostSafe, mode); - } - else { - var result = null; - var prevUsesImplicitReceiver = this.usesImplicitReceiver; - var receiver = this._visit(ast.receiver, _Mode.Expression); - if (receiver === this._implicitReceiver) { - result = this._getLocal(ast.name); - if (result) { - // Restore the previous "usesImplicitReceiver" state since the implicit - // receiver has been replaced with a resolved local expression. - this.usesImplicitReceiver = prevUsesImplicitReceiver; - } - } - if (result == null) { - result = receiver.prop(ast.name); - } - return convertToStatementIfNeeded(mode, result); - } - }; - _AstToIrVisitor.prototype.visitPropertyWrite = function (ast, mode) { - var receiver = this._visit(ast.receiver, _Mode.Expression); - var prevUsesImplicitReceiver = this.usesImplicitReceiver; - var varExpr = null; - if (receiver === this._implicitReceiver) { - var localExpr = this._getLocal(ast.name); - if (localExpr) { - if (localExpr instanceof ReadPropExpr) { - // If the local variable is a property read expression, it's a reference - // to a 'context.property' value and will be used as the target of the - // write expression. - varExpr = localExpr; - // Restore the previous "usesImplicitReceiver" state since the implicit - // receiver has been replaced with a resolved local expression. - this.usesImplicitReceiver = prevUsesImplicitReceiver; - } - else { - // Otherwise it's an error. - throw new Error('Cannot assign to a reference or variable!'); - } - } - } - // If no local expression could be produced, use the original receiver's - // property as the target. - if (varExpr === null) { - varExpr = receiver.prop(ast.name); - } - return convertToStatementIfNeeded(mode, varExpr.set(this._visit(ast.value, _Mode.Expression))); - }; - _AstToIrVisitor.prototype.visitSafePropertyRead = function (ast, mode) { - return this.convertSafeAccess(ast, this.leftMostSafeNode(ast), mode); - }; - _AstToIrVisitor.prototype.visitSafeMethodCall = function (ast, mode) { - return this.convertSafeAccess(ast, this.leftMostSafeNode(ast), mode); - }; - _AstToIrVisitor.prototype.visitAll = function (asts, mode) { - var _this = this; - return asts.map(function (ast) { return _this._visit(ast, mode); }); - }; - _AstToIrVisitor.prototype.visitQuote = function (ast, mode) { - throw new Error("Quotes are not supported for evaluation!\n Statement: " + ast.uninterpretedExpression + " located at " + ast.location); - }; - _AstToIrVisitor.prototype._visit = function (ast, mode) { - var result = this._resultMap.get(ast); - if (result) - return result; - return (this._nodeMap.get(ast) || ast).visit(this, mode); - }; - _AstToIrVisitor.prototype.convertSafeAccess = function (ast, leftMostSafe, mode) { - // If the expression contains a safe access node on the left it needs to be converted to - // an expression that guards the access to the member by checking the receiver for blank. As - // execution proceeds from left to right, the left most part of the expression must be guarded - // first but, because member access is left associative, the right side of the expression is at - // the top of the AST. The desired result requires lifting a copy of the the left part of the - // expression up to test it for blank before generating the unguarded version. - // Consider, for example the following expression: a?.b.c?.d.e - // This results in the ast: - // . - // / \ - // ?. e - // / \ - // . d - // / \ - // ?. c - // / \ - // a b - // The following tree should be generated: - // - // /---- ? ----\ - // / | \ - // a /--- ? ---\ null - // / | \ - // . . null - // / \ / \ - // . c . e - // / \ / \ - // a b . d - // / \ - // . c - // / \ - // a b - // - // Notice that the first guard condition is the left hand of the left most safe access node - // which comes in as leftMostSafe to this routine. - var guardedExpression = this._visit(leftMostSafe.receiver, _Mode.Expression); - var temporary = undefined; - if (this.needsTemporary(leftMostSafe.receiver)) { - // If the expression has method calls or pipes then we need to save the result into a - // temporary variable to avoid calling stateful or impure code more than once. - temporary = this.allocateTemporary(); - // Preserve the result in the temporary variable - guardedExpression = temporary.set(guardedExpression); - // Ensure all further references to the guarded expression refer to the temporary instead. - this._resultMap.set(leftMostSafe.receiver, temporary); - } - var condition = guardedExpression.isBlank(); - // Convert the ast to an unguarded access to the receiver's member. The map will substitute - // leftMostNode with its unguarded version in the call to `this.visit()`. - if (leftMostSafe instanceof SafeMethodCall) { - this._nodeMap.set(leftMostSafe, new MethodCall(leftMostSafe.span, leftMostSafe.receiver, leftMostSafe.name, leftMostSafe.args)); - } - else { - this._nodeMap.set(leftMostSafe, new PropertyRead(leftMostSafe.span, leftMostSafe.receiver, leftMostSafe.name)); - } - // Recursively convert the node now without the guarded member access. - var access = this._visit(ast, _Mode.Expression); - // Remove the mapping. This is not strictly required as the converter only traverses each node - // once but is safer if the conversion is changed to traverse the nodes more than once. - this._nodeMap.delete(leftMostSafe); - // If we allocated a temporary, release it. - if (temporary) { - this.releaseTemporary(temporary); - } - // Produce the conditional - return convertToStatementIfNeeded(mode, condition.conditional(literal(null), access)); - }; - // Given a expression of the form a?.b.c?.d.e the the left most safe node is - // the (a?.b). The . and ?. are left associative thus can be rewritten as: - // ((((a?.c).b).c)?.d).e. This returns the most deeply nested safe read or - // safe method call as this needs be transform initially to: - // a == null ? null : a.c.b.c?.d.e - // then to: - // a == null ? null : a.b.c == null ? null : a.b.c.d.e - _AstToIrVisitor.prototype.leftMostSafeNode = function (ast) { - var _this = this; - var visit = function (visitor, ast) { - return (_this._nodeMap.get(ast) || ast).visit(visitor); - }; - return ast.visit({ - visitBinary: function (ast) { return null; }, - visitChain: function (ast) { return null; }, - visitConditional: function (ast) { return null; }, - visitFunctionCall: function (ast) { return null; }, - visitImplicitReceiver: function (ast) { return null; }, - visitInterpolation: function (ast) { return null; }, - visitKeyedRead: function (ast) { return visit(this, ast.obj); }, - visitKeyedWrite: function (ast) { return null; }, - visitLiteralArray: function (ast) { return null; }, - visitLiteralMap: function (ast) { return null; }, - visitLiteralPrimitive: function (ast) { return null; }, - visitMethodCall: function (ast) { return visit(this, ast.receiver); }, - visitPipe: function (ast) { return null; }, - visitPrefixNot: function (ast) { return null; }, - visitNonNullAssert: function (ast) { return null; }, - visitPropertyRead: function (ast) { return visit(this, ast.receiver); }, - visitPropertyWrite: function (ast) { return null; }, - visitQuote: function (ast) { return null; }, - visitSafeMethodCall: function (ast) { return visit(this, ast.receiver) || ast; }, - visitSafePropertyRead: function (ast) { - return visit(this, ast.receiver) || ast; - } - }); - }; - // Returns true of the AST includes a method or a pipe indicating that, if the - // expression is used as the target of a safe property or method access then - // the expression should be stored into a temporary variable. - _AstToIrVisitor.prototype.needsTemporary = function (ast) { - var _this = this; - var visit = function (visitor, ast) { - return ast && (_this._nodeMap.get(ast) || ast).visit(visitor); - }; - var visitSome = function (visitor, ast) { - return ast.some(function (ast) { return visit(visitor, ast); }); - }; - return ast.visit({ - visitBinary: function (ast) { return visit(this, ast.left) || visit(this, ast.right); }, - visitChain: function (ast) { return false; }, - visitConditional: function (ast) { - return visit(this, ast.condition) || visit(this, ast.trueExp) || - visit(this, ast.falseExp); - }, - visitFunctionCall: function (ast) { return true; }, - visitImplicitReceiver: function (ast) { return false; }, - visitInterpolation: function (ast) { return visitSome(this, ast.expressions); }, - visitKeyedRead: function (ast) { return false; }, - visitKeyedWrite: function (ast) { return false; }, - visitLiteralArray: function (ast) { return true; }, - visitLiteralMap: function (ast) { return true; }, - visitLiteralPrimitive: function (ast) { return false; }, - visitMethodCall: function (ast) { return true; }, - visitPipe: function (ast) { return true; }, - visitPrefixNot: function (ast) { return visit(this, ast.expression); }, - visitNonNullAssert: function (ast) { return visit(this, ast.expression); }, - visitPropertyRead: function (ast) { return false; }, - visitPropertyWrite: function (ast) { return false; }, - visitQuote: function (ast) { return false; }, - visitSafeMethodCall: function (ast) { return true; }, - visitSafePropertyRead: function (ast) { return false; } - }); - }; - _AstToIrVisitor.prototype.allocateTemporary = function () { - var tempNumber = this._currentTemporary++; - this.temporaryCount = Math.max(this._currentTemporary, this.temporaryCount); - return new ReadVarExpr(temporaryName(this.bindingId, tempNumber)); - }; - _AstToIrVisitor.prototype.releaseTemporary = function (temporary) { - this._currentTemporary--; - if (temporary.name != temporaryName(this.bindingId, this._currentTemporary)) { - throw new Error("Temporary " + temporary.name + " released out of order"); - } - }; - /** - * Creates an absolute `ParseSourceSpan` from the relative `ParseSpan`. - * - * `ParseSpan` objects are relative to the start of the expression. - * This method converts these to full `ParseSourceSpan` objects that - * show where the span is within the overall source file. - * - * @param span the relative span to convert. - * @returns a `ParseSourceSpan` for the the given span or null if no - * `baseSourceSpan` was provided to this class. - */ - _AstToIrVisitor.prototype.convertSourceSpan = function (span) { - if (this.baseSourceSpan) { - var start = this.baseSourceSpan.start.moveBy(span.start); - var end = this.baseSourceSpan.start.moveBy(span.end); - return new ParseSourceSpan(start, end); - } - else { - return null; - } - }; - return _AstToIrVisitor; -}()); -function flattenStatements(arg, output) { - if (Array.isArray(arg)) { - arg.forEach(function (entry) { return flattenStatements(entry, output); }); - } - else { - output.push(arg); - } -} -var DefaultLocalResolver = /** @class */ (function () { - function DefaultLocalResolver() { - } - DefaultLocalResolver.prototype.notifyImplicitReceiverUse = function () { }; - DefaultLocalResolver.prototype.getLocal = function (name) { - if (name === EventHandlerVars.event.name) { - return EventHandlerVars.event; - } - return null; - }; - return DefaultLocalResolver; -}()); -function createCurrValueExpr(bindingId) { - return variable("currVal_" + bindingId); // fix syntax highlighting: ` -} -function createPreventDefaultVar(bindingId) { - return variable("pd_" + bindingId); -} -function convertStmtIntoExpression(stmt) { - if (stmt instanceof ExpressionStatement) { - return stmt.expr; - } - else if (stmt instanceof ReturnStatement) { - return stmt.value; - } - return null; -} -var BuiltinFunctionCall = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(BuiltinFunctionCall, _super); - function BuiltinFunctionCall(span, args, converter) { - var _this = _super.call(this, span, null, args) || this; - _this.args = args; - _this.converter = converter; - return _this; - } - return BuiltinFunctionCall; -}(FunctionCall)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * This file is a port of shadowCSS from webcomponents.js to TypeScript. - * - * Please make sure to keep to edits in sync with the source file. - * - * Source: - * https://github.com/webcomponents/webcomponentsjs/blob/4efecd7e0e/src/ShadowCSS/ShadowCSS.js - * - * The original file level comment is reproduced below - */ -/* - This is a limited shim for ShadowDOM css styling. - https://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#styles - - The intention here is to support only the styling features which can be - relatively simply implemented. The goal is to allow users to avoid the - most obvious pitfalls and do so without compromising performance significantly. - For ShadowDOM styling that's not covered here, a set of best practices - can be provided that should allow users to accomplish more complex styling. - - The following is a list of specific ShadowDOM styling features and a brief - discussion of the approach used to shim. - - Shimmed features: - - * :host, :host-context: ShadowDOM allows styling of the shadowRoot's host - element using the :host rule. To shim this feature, the :host styles are - reformatted and prefixed with a given scope name and promoted to a - document level stylesheet. - For example, given a scope name of .foo, a rule like this: - - :host { - background: red; - } - } - - becomes: - - .foo { - background: red; - } - - * encapsulation: Styles defined within ShadowDOM, apply only to - dom inside the ShadowDOM. Polymer uses one of two techniques to implement - this feature. - - By default, rules are prefixed with the host element tag name - as a descendant selector. This ensures styling does not leak out of the 'top' - of the element's ShadowDOM. For example, - - div { - font-weight: bold; - } - - becomes: - - x-foo div { - font-weight: bold; - } - - becomes: - - - Alternatively, if WebComponents.ShadowCSS.strictStyling is set to true then - selectors are scoped by adding an attribute selector suffix to each - simple selector that contains the host element tag name. Each element - in the element's ShadowDOM template is also given the scope attribute. - Thus, these rules match only elements that have the scope attribute. - For example, given a scope name of x-foo, a rule like this: - - div { - font-weight: bold; - } - - becomes: - - div[x-foo] { - font-weight: bold; - } - - Note that elements that are dynamically added to a scope must have the scope - selector added to them manually. - - * upper/lower bound encapsulation: Styles which are defined outside a - shadowRoot should not cross the ShadowDOM boundary and should not apply - inside a shadowRoot. - - This styling behavior is not emulated. Some possible ways to do this that - were rejected due to complexity and/or performance concerns include: (1) reset - every possible property for every possible selector for a given scope name; - (2) re-implement css in javascript. - - As an alternative, users should make sure to use selectors - specific to the scope in which they are working. - - * ::distributed: This behavior is not emulated. It's often not necessary - to style the contents of a specific insertion point and instead, descendants - of the host element can be styled selectively. Users can also create an - extra node around an insertion point and style that node's contents - via descendent selectors. For example, with a shadowRoot like this: - - - - - could become: - - -
    - -
    - - Note the use of @polyfill in the comment above a ShadowDOM specific style - declaration. This is a directive to the styling shim to use the selector - in comments in lieu of the next selector when running under polyfill. -*/ -var ShadowCss = /** @class */ (function () { - function ShadowCss() { - this.strictStyling = true; - } - /* - * Shim some cssText with the given selector. Returns cssText that can - * be included in the document via WebComponents.ShadowCSS.addCssToDocument(css). - * - * When strictStyling is true: - * - selector is the attribute added to all elements inside the host, - * - hostSelector is the attribute added to the host itself. - */ - ShadowCss.prototype.shimCssText = function (cssText, selector, hostSelector) { - if (hostSelector === void 0) { hostSelector = ''; } - var commentsWithHash = extractCommentsWithHash(cssText); - cssText = stripComments(cssText); - cssText = this._insertDirectives(cssText); - var scopedCssText = this._scopeCssText(cssText, selector, hostSelector); - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([scopedCssText], commentsWithHash).join('\n'); - }; - ShadowCss.prototype._insertDirectives = function (cssText) { - cssText = this._insertPolyfillDirectivesInCssText(cssText); - return this._insertPolyfillRulesInCssText(cssText); - }; - /* - * Process styles to convert native ShadowDOM rules that will trip - * up the css parser; we rely on decorating the stylesheet with inert rules. - * - * For example, we convert this rule: - * - * polyfill-next-selector { content: ':host menu-item'; } - * ::content menu-item { - * - * to this: - * - * scopeName menu-item { - * - **/ - ShadowCss.prototype._insertPolyfillDirectivesInCssText = function (cssText) { - // Difference with webcomponents.js: does not handle comments - return cssText.replace(_cssContentNextSelectorRe, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - return m[2] + '{'; - }); - }; - /* - * Process styles to add rules which will only apply under the polyfill - * - * For example, we convert this rule: - * - * polyfill-rule { - * content: ':host menu-item'; - * ... - * } - * - * to this: - * - * scopeName menu-item {...} - * - **/ - ShadowCss.prototype._insertPolyfillRulesInCssText = function (cssText) { - // Difference with webcomponents.js: does not handle comments - return cssText.replace(_cssContentRuleRe, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - var rule = m[0].replace(m[1], '').replace(m[2], ''); - return m[4] + rule; - }); - }; - /* Ensure styles are scoped. Pseudo-scoping takes a rule like: - * - * .foo {... } - * - * and converts this to - * - * scopeName .foo { ... } - */ - ShadowCss.prototype._scopeCssText = function (cssText, scopeSelector, hostSelector) { - var unscopedRules = this._extractUnscopedRulesFromCssText(cssText); - // replace :host and :host-context -shadowcsshost and -shadowcsshost respectively - cssText = this._insertPolyfillHostInCssText(cssText); - cssText = this._convertColonHost(cssText); - cssText = this._convertColonHostContext(cssText); - cssText = this._convertShadowDOMSelectors(cssText); - if (scopeSelector) { - cssText = this._scopeSelectors(cssText, scopeSelector, hostSelector); - } - cssText = cssText + '\n' + unscopedRules; - return cssText.trim(); - }; - /* - * Process styles to add rules which will only apply under the polyfill - * and do not process via CSSOM. (CSSOM is destructive to rules on rare - * occasions, e.g. -webkit-calc on Safari.) - * For example, we convert this rule: - * - * @polyfill-unscoped-rule { - * content: 'menu-item'; - * ... } - * - * to this: - * - * menu-item {...} - * - **/ - ShadowCss.prototype._extractUnscopedRulesFromCssText = function (cssText) { - // Difference with webcomponents.js: does not handle comments - var r = ''; - var m; - _cssContentUnscopedRuleRe.lastIndex = 0; - while ((m = _cssContentUnscopedRuleRe.exec(cssText)) !== null) { - var rule = m[0].replace(m[2], '').replace(m[1], m[4]); - r += rule + '\n\n'; - } - return r; - }; - /* - * convert a rule like :host(.foo) > .bar { } - * - * to - * - * .foo > .bar - */ - ShadowCss.prototype._convertColonHost = function (cssText) { - return this._convertColonRule(cssText, _cssColonHostRe, this._colonHostPartReplacer); - }; - /* - * convert a rule like :host-context(.foo) > .bar { } - * - * to - * - * .foo > .bar, .foo scopeName > .bar { } - * - * and - * - * :host-context(.foo:host) .bar { ... } - * - * to - * - * .foo .bar { ... } - */ - ShadowCss.prototype._convertColonHostContext = function (cssText) { - return this._convertColonRule(cssText, _cssColonHostContextRe, this._colonHostContextPartReplacer); - }; - ShadowCss.prototype._convertColonRule = function (cssText, regExp, partReplacer) { - // m[1] = :host(-context), m[2] = contents of (), m[3] rest of rule - return cssText.replace(regExp, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - if (m[2]) { - var parts = m[2].split(','); - var r = []; - for (var i = 0; i < parts.length; i++) { - var p = parts[i].trim(); - if (!p) - break; - r.push(partReplacer(_polyfillHostNoCombinator, p, m[3])); - } - return r.join(','); - } - else { - return _polyfillHostNoCombinator + m[3]; - } - }); - }; - ShadowCss.prototype._colonHostContextPartReplacer = function (host, part, suffix) { - if (part.indexOf(_polyfillHost) > -1) { - return this._colonHostPartReplacer(host, part, suffix); - } - else { - return host + part + suffix + ', ' + part + ' ' + host + suffix; - } - }; - ShadowCss.prototype._colonHostPartReplacer = function (host, part, suffix) { - return host + part.replace(_polyfillHost, '') + suffix; - }; - /* - * Convert combinators like ::shadow and pseudo-elements like ::content - * by replacing with space. - */ - ShadowCss.prototype._convertShadowDOMSelectors = function (cssText) { - return _shadowDOMSelectorsRe.reduce(function (result, pattern) { return result.replace(pattern, ' '); }, cssText); - }; - // change a selector like 'div' to 'name div' - ShadowCss.prototype._scopeSelectors = function (cssText, scopeSelector, hostSelector) { - var _this = this; - return processRules(cssText, function (rule) { - var selector = rule.selector; - var content = rule.content; - if (rule.selector[0] != '@') { - selector = - _this._scopeSelector(rule.selector, scopeSelector, hostSelector, _this.strictStyling); - } - else if (rule.selector.startsWith('@media') || rule.selector.startsWith('@supports') || - rule.selector.startsWith('@page') || rule.selector.startsWith('@document')) { - content = _this._scopeSelectors(rule.content, scopeSelector, hostSelector); - } - return new CssRule(selector, content); - }); - }; - ShadowCss.prototype._scopeSelector = function (selector, scopeSelector, hostSelector, strict) { - var _this = this; - return selector.split(',') - .map(function (part) { return part.trim().split(_shadowDeepSelectors); }) - .map(function (deepParts) { - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(deepParts), shallowPart = _a[0], otherParts = _a.slice(1); - var applyScope = function (shallowPart) { - if (_this._selectorNeedsScoping(shallowPart, scopeSelector)) { - return strict ? - _this._applyStrictSelectorScope(shallowPart, scopeSelector, hostSelector) : - _this._applySelectorScope(shallowPart, scopeSelector, hostSelector); - } - else { - return shallowPart; - } - }; - return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])([applyScope(shallowPart)], otherParts).join(' '); - }) - .join(', '); - }; - ShadowCss.prototype._selectorNeedsScoping = function (selector, scopeSelector) { - var re = this._makeScopeMatcher(scopeSelector); - return !re.test(selector); - }; - ShadowCss.prototype._makeScopeMatcher = function (scopeSelector) { - var lre = /\[/g; - var rre = /\]/g; - scopeSelector = scopeSelector.replace(lre, '\\[').replace(rre, '\\]'); - return new RegExp('^(' + scopeSelector + ')' + _selectorReSuffix, 'm'); - }; - ShadowCss.prototype._applySelectorScope = function (selector, scopeSelector, hostSelector) { - // Difference from webcomponents.js: scopeSelector could not be an array - return this._applySimpleSelectorScope(selector, scopeSelector, hostSelector); - }; - // scope via name and [is=name] - ShadowCss.prototype._applySimpleSelectorScope = function (selector, scopeSelector, hostSelector) { - // In Android browser, the lastIndex is not reset when the regex is used in String.replace() - _polyfillHostRe.lastIndex = 0; - if (_polyfillHostRe.test(selector)) { - var replaceBy_1 = this.strictStyling ? "[" + hostSelector + "]" : scopeSelector; - return selector - .replace(_polyfillHostNoCombinatorRe, function (hnc, selector) { - return selector.replace(/([^:]*)(:*)(.*)/, function (_, before, colon, after) { - return before + replaceBy_1 + colon + after; - }); - }) - .replace(_polyfillHostRe, replaceBy_1 + ' '); - } - return scopeSelector + ' ' + selector; - }; - // return a selector with [name] suffix on each simple selector - // e.g. .foo.bar > .zot becomes .foo[name].bar[name] > .zot[name] /** @internal */ - ShadowCss.prototype._applyStrictSelectorScope = function (selector, scopeSelector, hostSelector) { - var _this = this; - var isRe = /\[is=([^\]]*)\]/g; - scopeSelector = scopeSelector.replace(isRe, function (_) { - var parts = []; - for (var _i = 1; _i < arguments.length; _i++) { - parts[_i - 1] = arguments[_i]; - } - return parts[0]; - }); - var attrName = '[' + scopeSelector + ']'; - var _scopeSelectorPart = function (p) { - var scopedP = p.trim(); - if (!scopedP) { - return ''; - } - if (p.indexOf(_polyfillHostNoCombinator) > -1) { - scopedP = _this._applySimpleSelectorScope(p, scopeSelector, hostSelector); - } - else { - // remove :host since it should be unnecessary - var t = p.replace(_polyfillHostRe, ''); - if (t.length > 0) { - var matches = t.match(/([^:]*)(:*)(.*)/); - if (matches) { - scopedP = matches[1] + attrName + matches[2] + matches[3]; - } - } - } - return scopedP; - }; - var safeContent = new SafeSelector(selector); - selector = safeContent.content(); - var scopedSelector = ''; - var startIndex = 0; - var res; - var sep = /( |>|\+|~(?!=))\s*/g; - // If a selector appears before :host it should not be shimmed as it - // matches on ancestor elements and not on elements in the host's shadow - // `:host-context(div)` is transformed to - // `-shadowcsshost-no-combinatordiv, div -shadowcsshost-no-combinator` - // the `div` is not part of the component in the 2nd selectors and should not be scoped. - // Historically `component-tag:host` was matching the component so we also want to preserve - // this behavior to avoid breaking legacy apps (it should not match). - // The behavior should be: - // - `tag:host` -> `tag[h]` (this is to avoid breaking legacy apps, should not match anything) - // - `tag :host` -> `tag [h]` (`tag` is not scoped because it's considered part of a - // `:host-context(tag)`) - var hasHost = selector.indexOf(_polyfillHostNoCombinator) > -1; - // Only scope parts after the first `-shadowcsshost-no-combinator` when it is present - var shouldScope = !hasHost; - while ((res = sep.exec(selector)) !== null) { - var separator = res[1]; - var part_1 = selector.slice(startIndex, res.index).trim(); - shouldScope = shouldScope || part_1.indexOf(_polyfillHostNoCombinator) > -1; - var scopedPart = shouldScope ? _scopeSelectorPart(part_1) : part_1; - scopedSelector += scopedPart + " " + separator + " "; - startIndex = sep.lastIndex; - } - var part = selector.substring(startIndex); - shouldScope = shouldScope || part.indexOf(_polyfillHostNoCombinator) > -1; - scopedSelector += shouldScope ? _scopeSelectorPart(part) : part; - // replace the placeholders with their original values - return safeContent.restore(scopedSelector); - }; - ShadowCss.prototype._insertPolyfillHostInCssText = function (selector) { - return selector.replace(_colonHostContextRe, _polyfillHostContext) - .replace(_colonHostRe, _polyfillHost); - }; - return ShadowCss; -}()); -var SafeSelector = /** @class */ (function () { - function SafeSelector(selector) { - var _this = this; - this.placeholders = []; - this.index = 0; - // Replaces attribute selectors with placeholders. - // The WS in [attr="va lue"] would otherwise be interpreted as a selector separator. - selector = selector.replace(/(\[[^\]]*\])/g, function (_, keep) { - var replaceBy = "__ph-" + _this.index + "__"; - _this.placeholders.push(keep); - _this.index++; - return replaceBy; - }); - // Replaces the expression in `:nth-child(2n + 1)` with a placeholder. - // WS and "+" would otherwise be interpreted as selector separators. - this._content = selector.replace(/(:nth-[-\w]+)(\([^)]+\))/g, function (_, pseudo, exp) { - var replaceBy = "__ph-" + _this.index + "__"; - _this.placeholders.push(exp); - _this.index++; - return pseudo + replaceBy; - }); - } - SafeSelector.prototype.restore = function (content) { - var _this = this; - return content.replace(/__ph-(\d+)__/g, function (ph, index) { return _this.placeholders[+index]; }); - }; - SafeSelector.prototype.content = function () { return this._content; }; - return SafeSelector; -}()); -var _cssContentNextSelectorRe = /polyfill-next-selector[^}]*content:[\s]*?(['"])(.*?)\1[;\s]*}([^{]*?){/gim; -var _cssContentRuleRe = /(polyfill-rule)[^}]*(content:[\s]*(['"])(.*?)\3)[;\s]*[^}]*}/gim; -var _cssContentUnscopedRuleRe = /(polyfill-unscoped-rule)[^}]*(content:[\s]*(['"])(.*?)\3)[;\s]*[^}]*}/gim; -var _polyfillHost = '-shadowcsshost'; -// note: :host-context pre-processed to -shadowcsshostcontext. -var _polyfillHostContext = '-shadowcsscontext'; -var _parenSuffix = ')(?:\\((' + - '(?:\\([^)(]*\\)|[^)(]*)+?' + - ')\\))?([^,{]*)'; -var _cssColonHostRe = new RegExp('(' + _polyfillHost + _parenSuffix, 'gim'); -var _cssColonHostContextRe = new RegExp('(' + _polyfillHostContext + _parenSuffix, 'gim'); -var _polyfillHostNoCombinator = _polyfillHost + '-no-combinator'; -var _polyfillHostNoCombinatorRe = /-shadowcsshost-no-combinator([^\s]*)/; -var _shadowDOMSelectorsRe = [ - /::shadow/g, - /::content/g, - // Deprecated selectors - /\/shadow-deep\//g, - /\/shadow\//g, -]; -// The deep combinator is deprecated in the CSS spec -// Support for `>>>`, `deep`, `::ng-deep` is then also deprecated and will be removed in the future. -// see https://github.com/angular/angular/pull/17677 -var _shadowDeepSelectors = /(?:>>>)|(?:\/deep\/)|(?:::ng-deep)/g; -var _selectorReSuffix = '([>\\s~+\[.,{:][\\s\\S]*)?$'; -var _polyfillHostRe = /-shadowcsshost/gim; -var _colonHostRe = /:host/gim; -var _colonHostContextRe = /:host-context/gim; -var _commentRe = /\/\*\s*[\s\S]*?\*\//g; -function stripComments(input) { - return input.replace(_commentRe, ''); -} -var _commentWithHashRe = /\/\*\s*#\s*source(Mapping)?URL=[\s\S]+?\*\//g; -function extractCommentsWithHash(input) { - return input.match(_commentWithHashRe) || []; -} -var _ruleRe = /(\s*)([^;\{\}]+?)(\s*)((?:{%BLOCK%}?\s*;?)|(?:\s*;))/g; -var _curlyRe = /([{}])/g; -var OPEN_CURLY = '{'; -var CLOSE_CURLY = '}'; -var BLOCK_PLACEHOLDER = '%BLOCK%'; -var CssRule = /** @class */ (function () { - function CssRule(selector, content) { - this.selector = selector; - this.content = content; - } - return CssRule; -}()); -function processRules(input, ruleCallback) { - var inputWithEscapedBlocks = escapeBlocks(input); - var nextBlockIndex = 0; - return inputWithEscapedBlocks.escapedString.replace(_ruleRe, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - var selector = m[2]; - var content = ''; - var suffix = m[4]; - var contentPrefix = ''; - if (suffix && suffix.startsWith('{' + BLOCK_PLACEHOLDER)) { - content = inputWithEscapedBlocks.blocks[nextBlockIndex++]; - suffix = suffix.substring(BLOCK_PLACEHOLDER.length + 1); - contentPrefix = '{'; - } - var rule = ruleCallback(new CssRule(selector, content)); - return "" + m[1] + rule.selector + m[3] + contentPrefix + rule.content + suffix; - }); -} -var StringWithEscapedBlocks = /** @class */ (function () { - function StringWithEscapedBlocks(escapedString, blocks) { - this.escapedString = escapedString; - this.blocks = blocks; - } - return StringWithEscapedBlocks; -}()); -function escapeBlocks(input) { - var inputParts = input.split(_curlyRe); - var resultParts = []; - var escapedBlocks = []; - var bracketCount = 0; - var currentBlockParts = []; - for (var partIndex = 0; partIndex < inputParts.length; partIndex++) { - var part = inputParts[partIndex]; - if (part == CLOSE_CURLY) { - bracketCount--; - } - if (bracketCount > 0) { - currentBlockParts.push(part); - } - else { - if (currentBlockParts.length > 0) { - escapedBlocks.push(currentBlockParts.join('')); - resultParts.push(BLOCK_PLACEHOLDER); - currentBlockParts = []; - } - resultParts.push(part); - } - if (part == OPEN_CURLY) { - bracketCount++; - } - } - if (currentBlockParts.length > 0) { - escapedBlocks.push(currentBlockParts.join('')); - resultParts.push(BLOCK_PLACEHOLDER); - } - return new StringWithEscapedBlocks(resultParts.join(''), escapedBlocks); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var COMPONENT_VARIABLE = '%COMP%'; -var HOST_ATTR = "_nghost-" + COMPONENT_VARIABLE; -var CONTENT_ATTR = "_ngcontent-" + COMPONENT_VARIABLE; -var StylesCompileDependency = /** @class */ (function () { - function StylesCompileDependency(name, moduleUrl, setValue) { - this.name = name; - this.moduleUrl = moduleUrl; - this.setValue = setValue; - } - return StylesCompileDependency; -}()); -var CompiledStylesheet = /** @class */ (function () { - function CompiledStylesheet(outputCtx, stylesVar, dependencies, isShimmed, meta) { - this.outputCtx = outputCtx; - this.stylesVar = stylesVar; - this.dependencies = dependencies; - this.isShimmed = isShimmed; - this.meta = meta; - } - return CompiledStylesheet; -}()); -var StyleCompiler = /** @class */ (function () { - function StyleCompiler(_urlResolver) { - this._urlResolver = _urlResolver; - this._shadowCss = new ShadowCss(); - } - StyleCompiler.prototype.compileComponent = function (outputCtx, comp) { - var template = comp.template; - return this._compileStyles(outputCtx, comp, new CompileStylesheetMetadata({ - styles: template.styles, - styleUrls: template.styleUrls, - moduleUrl: identifierModuleUrl(comp.type) - }), this.needsStyleShim(comp), true); - }; - StyleCompiler.prototype.compileStyles = function (outputCtx, comp, stylesheet, shim) { - if (shim === void 0) { shim = this.needsStyleShim(comp); } - return this._compileStyles(outputCtx, comp, stylesheet, shim, false); - }; - StyleCompiler.prototype.needsStyleShim = function (comp) { - return comp.template.encapsulation === ViewEncapsulation.Emulated; - }; - StyleCompiler.prototype._compileStyles = function (outputCtx, comp, stylesheet, shim, isComponentStylesheet) { - var _this = this; - var styleExpressions = stylesheet.styles.map(function (plainStyle) { return literal(_this._shimIfNeeded(plainStyle, shim)); }); - var dependencies = []; - stylesheet.styleUrls.forEach(function (styleUrl) { - var exprIndex = styleExpressions.length; - // Note: This placeholder will be filled later. - styleExpressions.push(null); - dependencies.push(new StylesCompileDependency(getStylesVarName(null), styleUrl, function (value) { return styleExpressions[exprIndex] = outputCtx.importExpr(value); })); - }); - // styles variable contains plain strings and arrays of other styles arrays (recursive), - // so we set its type to dynamic. - var stylesVar = getStylesVarName(isComponentStylesheet ? comp : null); - var stmt = variable(stylesVar) - .set(literalArr(styleExpressions, new ArrayType(DYNAMIC_TYPE, [TypeModifier.Const]))) - .toDeclStmt(null, isComponentStylesheet ? [StmtModifier.Final] : [ - StmtModifier.Final, StmtModifier.Exported - ]); - outputCtx.statements.push(stmt); - return new CompiledStylesheet(outputCtx, stylesVar, dependencies, shim, stylesheet); - }; - StyleCompiler.prototype._shimIfNeeded = function (style, shim) { - return shim ? this._shadowCss.shimCssText(style, CONTENT_ATTR, HOST_ATTR) : style; - }; - return StyleCompiler; -}()); -function getStylesVarName(component) { - var result = "styles"; - if (component) { - result += "_" + identifierName(component.type); - } - return result; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -/** - * A path is an ordered set of elements. Typically a path is to a - * particular offset in a source file. The head of the list is the top - * most node. The tail is the node that contains the offset directly. - * - * For example, the expression `a + b + c` might have an ast that looks - * like: - * + - * / \ - * a + - * / \ - * b c - * - * The path to the node at offset 9 would be `['+' at 1-10, '+' at 7-10, - * 'c' at 9-10]` and the path the node at offset 1 would be - * `['+' at 1-10, 'a' at 1-2]`. - */ -var AstPath = /** @class */ (function () { - function AstPath(path, position) { - if (position === void 0) { position = -1; } - this.path = path; - this.position = position; - } - Object.defineProperty(AstPath.prototype, "empty", { - get: function () { return !this.path || !this.path.length; }, - enumerable: true, - configurable: true - }); - Object.defineProperty(AstPath.prototype, "head", { - get: function () { return this.path[0]; }, - enumerable: true, - configurable: true - }); - Object.defineProperty(AstPath.prototype, "tail", { - get: function () { return this.path[this.path.length - 1]; }, - enumerable: true, - configurable: true - }); - AstPath.prototype.parentOf = function (node) { - return node && this.path[this.path.indexOf(node) - 1]; - }; - AstPath.prototype.childOf = function (node) { return this.path[this.path.indexOf(node) + 1]; }; - AstPath.prototype.first = function (ctor) { - for (var i = this.path.length - 1; i >= 0; i--) { - var item = this.path[i]; - if (item instanceof ctor) - return item; - } - }; - AstPath.prototype.push = function (node) { this.path.push(node); }; - AstPath.prototype.pop = function () { return this.path.pop(); }; - return AstPath; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var Text$3 = /** @class */ (function () { - function Text(value, sourceSpan, i18n) { - this.value = value; - this.sourceSpan = sourceSpan; - this.i18n = i18n; - } - Text.prototype.visit = function (visitor, context) { return visitor.visitText(this, context); }; - return Text; -}()); -var Expansion = /** @class */ (function () { - function Expansion(switchValue, type, cases, sourceSpan, switchValueSourceSpan, i18n) { - this.switchValue = switchValue; - this.type = type; - this.cases = cases; - this.sourceSpan = sourceSpan; - this.switchValueSourceSpan = switchValueSourceSpan; - this.i18n = i18n; - } - Expansion.prototype.visit = function (visitor, context) { return visitor.visitExpansion(this, context); }; - return Expansion; -}()); -var ExpansionCase = /** @class */ (function () { - function ExpansionCase(value, expression, sourceSpan, valueSourceSpan, expSourceSpan) { - this.value = value; - this.expression = expression; - this.sourceSpan = sourceSpan; - this.valueSourceSpan = valueSourceSpan; - this.expSourceSpan = expSourceSpan; - } - ExpansionCase.prototype.visit = function (visitor, context) { return visitor.visitExpansionCase(this, context); }; - return ExpansionCase; -}()); -var Attribute = /** @class */ (function () { - function Attribute(name, value, sourceSpan, valueSpan, i18n) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - this.valueSpan = valueSpan; - this.i18n = i18n; - } - Attribute.prototype.visit = function (visitor, context) { return visitor.visitAttribute(this, context); }; - return Attribute; -}()); -var Element$1 = /** @class */ (function () { - function Element(name, attrs, children, sourceSpan, startSourceSpan, endSourceSpan, i18n) { - if (startSourceSpan === void 0) { startSourceSpan = null; } - if (endSourceSpan === void 0) { endSourceSpan = null; } - this.name = name; - this.attrs = attrs; - this.children = children; - this.sourceSpan = sourceSpan; - this.startSourceSpan = startSourceSpan; - this.endSourceSpan = endSourceSpan; - this.i18n = i18n; - } - Element.prototype.visit = function (visitor, context) { return visitor.visitElement(this, context); }; - return Element; -}()); -var Comment = /** @class */ (function () { - function Comment(value, sourceSpan) { - this.value = value; - this.sourceSpan = sourceSpan; - } - Comment.prototype.visit = function (visitor, context) { return visitor.visitComment(this, context); }; - return Comment; -}()); -function visitAll$1(visitor, nodes, context) { - if (context === void 0) { context = null; } - var result = []; - var visit = visitor.visit ? - function (ast) { return visitor.visit(ast, context) || ast.visit(visitor, context); } : - function (ast) { return ast.visit(visitor, context); }; - nodes.forEach(function (ast) { - var astResult = visit(ast); - if (astResult) { - result.push(astResult); - } - }); - return result; -} -var RecursiveVisitor$1 = /** @class */ (function () { - function RecursiveVisitor() { - } - RecursiveVisitor.prototype.visitElement = function (ast, context) { - this.visitChildren(context, function (visit) { - visit(ast.attrs); - visit(ast.children); - }); - }; - RecursiveVisitor.prototype.visitAttribute = function (ast, context) { }; - RecursiveVisitor.prototype.visitText = function (ast, context) { }; - RecursiveVisitor.prototype.visitComment = function (ast, context) { }; - RecursiveVisitor.prototype.visitExpansion = function (ast, context) { - return this.visitChildren(context, function (visit) { visit(ast.cases); }); - }; - RecursiveVisitor.prototype.visitExpansionCase = function (ast, context) { }; - RecursiveVisitor.prototype.visitChildren = function (context, cb) { - var results = []; - var t = this; - function visit(children) { - if (children) - results.push(visitAll$1(t, children, context)); - } - cb(visit); - return Array.prototype.concat.apply([], results); - }; - return RecursiveVisitor; -}()); -function spanOf(ast) { - var start = ast.sourceSpan.start.offset; - var end = ast.sourceSpan.end.offset; - if (ast instanceof Element$1) { - if (ast.endSourceSpan) { - end = ast.endSourceSpan.end.offset; - } - else if (ast.children && ast.children.length) { - end = spanOf(ast.children[ast.children.length - 1]).end; - } - } - return { start: start, end: end }; -} -function findNode(nodes, position) { - var path = []; - var visitor = new /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(class_1, _super); - function class_1() { - return _super !== null && _super.apply(this, arguments) || this; - } - class_1.prototype.visit = function (ast, context) { - var span = spanOf(ast); - if (span.start <= position && position < span.end) { - path.push(ast); - } - else { - // Returning a value here will result in the children being skipped. - return true; - } - }; - return class_1; - }(RecursiveVisitor$1)); - visitAll$1(visitor, nodes); - return new AstPath(path, position); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var TokenType; -(function (TokenType) { - TokenType[TokenType["TAG_OPEN_START"] = 0] = "TAG_OPEN_START"; - TokenType[TokenType["TAG_OPEN_END"] = 1] = "TAG_OPEN_END"; - TokenType[TokenType["TAG_OPEN_END_VOID"] = 2] = "TAG_OPEN_END_VOID"; - TokenType[TokenType["TAG_CLOSE"] = 3] = "TAG_CLOSE"; - TokenType[TokenType["TEXT"] = 4] = "TEXT"; - TokenType[TokenType["ESCAPABLE_RAW_TEXT"] = 5] = "ESCAPABLE_RAW_TEXT"; - TokenType[TokenType["RAW_TEXT"] = 6] = "RAW_TEXT"; - TokenType[TokenType["COMMENT_START"] = 7] = "COMMENT_START"; - TokenType[TokenType["COMMENT_END"] = 8] = "COMMENT_END"; - TokenType[TokenType["CDATA_START"] = 9] = "CDATA_START"; - TokenType[TokenType["CDATA_END"] = 10] = "CDATA_END"; - TokenType[TokenType["ATTR_NAME"] = 11] = "ATTR_NAME"; - TokenType[TokenType["ATTR_QUOTE"] = 12] = "ATTR_QUOTE"; - TokenType[TokenType["ATTR_VALUE"] = 13] = "ATTR_VALUE"; - TokenType[TokenType["DOC_TYPE"] = 14] = "DOC_TYPE"; - TokenType[TokenType["EXPANSION_FORM_START"] = 15] = "EXPANSION_FORM_START"; - TokenType[TokenType["EXPANSION_CASE_VALUE"] = 16] = "EXPANSION_CASE_VALUE"; - TokenType[TokenType["EXPANSION_CASE_EXP_START"] = 17] = "EXPANSION_CASE_EXP_START"; - TokenType[TokenType["EXPANSION_CASE_EXP_END"] = 18] = "EXPANSION_CASE_EXP_END"; - TokenType[TokenType["EXPANSION_FORM_END"] = 19] = "EXPANSION_FORM_END"; - TokenType[TokenType["EOF"] = 20] = "EOF"; -})(TokenType || (TokenType = {})); -var Token = /** @class */ (function () { - function Token(type, parts, sourceSpan) { - this.type = type; - this.parts = parts; - this.sourceSpan = sourceSpan; - } - return Token; -}()); -var TokenError = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(TokenError, _super); - function TokenError(errorMsg, tokenType, span) { - var _this = _super.call(this, span, errorMsg) || this; - _this.tokenType = tokenType; - return _this; - } - return TokenError; -}(ParseError)); -var TokenizeResult = /** @class */ (function () { - function TokenizeResult(tokens, errors) { - this.tokens = tokens; - this.errors = errors; - } - return TokenizeResult; -}()); -function tokenize(source, url, getTagDefinition, options) { - if (options === void 0) { options = {}; } - return new _Tokenizer(new ParseSourceFile(source, url), getTagDefinition, options).tokenize(); -} -var _CR_OR_CRLF_REGEXP = /\r\n?/g; -function _unexpectedCharacterErrorMsg(charCode) { - var char = charCode === $EOF ? 'EOF' : String.fromCharCode(charCode); - return "Unexpected character \"" + char + "\""; -} -function _unknownEntityErrorMsg(entitySrc) { - return "Unknown entity \"" + entitySrc + "\" - use the \"&#;\" or \"&#x;\" syntax"; -} -var _ControlFlowError = /** @class */ (function () { - function _ControlFlowError(error) { - this.error = error; - } - return _ControlFlowError; -}()); -// See http://www.w3.org/TR/html51/syntax.html#writing -var _Tokenizer = /** @class */ (function () { - /** - * @param _file The html source file being tokenized. - * @param _getTagDefinition A function that will retrieve a tag definition for a given tag name. - * @param options Configuration of the tokenization. - */ - function _Tokenizer(_file, _getTagDefinition, options) { - this._getTagDefinition = _getTagDefinition; - this._currentTokenStart = null; - this._currentTokenType = null; - this._expansionCaseStack = []; - this._inInterpolation = false; - this.tokens = []; - this.errors = []; - this._tokenizeIcu = options.tokenizeExpansionForms || false; - this._interpolationConfig = options.interpolationConfig || DEFAULT_INTERPOLATION_CONFIG; - this._leadingTriviaCodePoints = - options.leadingTriviaChars && options.leadingTriviaChars.map(function (c) { return c.codePointAt(0) || 0; }); - var range = options.range || { endPos: _file.content.length, startPos: 0, startLine: 0, startCol: 0 }; - this._cursor = options.escapedString ? new EscapedCharacterCursor(_file, range) : - new PlainCharacterCursor(_file, range); - try { - this._cursor.init(); - } - catch (e) { - this.handleError(e); - } - } - _Tokenizer.prototype._processCarriageReturns = function (content) { - // http://www.w3.org/TR/html5/syntax.html#preprocessing-the-input-stream - // In order to keep the original position in the source, we can not - // pre-process it. - // Instead CRs are processed right before instantiating the tokens. - return content.replace(_CR_OR_CRLF_REGEXP, '\n'); - }; - _Tokenizer.prototype.tokenize = function () { - while (this._cursor.peek() !== $EOF) { - var start = this._cursor.clone(); - try { - if (this._attemptCharCode($LT)) { - if (this._attemptCharCode($BANG)) { - if (this._attemptCharCode($LBRACKET)) { - this._consumeCdata(start); - } - else if (this._attemptCharCode($MINUS)) { - this._consumeComment(start); - } - else { - this._consumeDocType(start); - } - } - else if (this._attemptCharCode($SLASH)) { - this._consumeTagClose(start); - } - else { - this._consumeTagOpen(start); - } - } - else if (!(this._tokenizeIcu && this._tokenizeExpansionForm())) { - this._consumeText(); - } - } - catch (e) { - this.handleError(e); - } - } - this._beginToken(TokenType.EOF); - this._endToken([]); - return new TokenizeResult(mergeTextTokens(this.tokens), this.errors); - }; - /** - * @returns whether an ICU token has been created - * @internal - */ - _Tokenizer.prototype._tokenizeExpansionForm = function () { - if (this.isExpansionFormStart()) { - this._consumeExpansionFormStart(); - return true; - } - if (isExpansionCaseStart(this._cursor.peek()) && this._isInExpansionForm()) { - this._consumeExpansionCaseStart(); - return true; - } - if (this._cursor.peek() === $RBRACE) { - if (this._isInExpansionCase()) { - this._consumeExpansionCaseEnd(); - return true; - } - if (this._isInExpansionForm()) { - this._consumeExpansionFormEnd(); - return true; - } - } - return false; - }; - _Tokenizer.prototype._beginToken = function (type, start) { - if (start === void 0) { start = this._cursor.clone(); } - this._currentTokenStart = start; - this._currentTokenType = type; - }; - _Tokenizer.prototype._endToken = function (parts, end) { - if (end === void 0) { end = this._cursor.clone(); } - if (this._currentTokenStart === null) { - throw new TokenError('Programming error - attempted to end a token when there was no start to the token', this._currentTokenType, this._cursor.getSpan(end)); - } - if (this._currentTokenType === null) { - throw new TokenError('Programming error - attempted to end a token which has no token type', null, this._cursor.getSpan(this._currentTokenStart)); - } - var token = new Token(this._currentTokenType, parts, this._cursor.getSpan(this._currentTokenStart, this._leadingTriviaCodePoints)); - this.tokens.push(token); - this._currentTokenStart = null; - this._currentTokenType = null; - return token; - }; - _Tokenizer.prototype._createError = function (msg, span) { - if (this._isInExpansionForm()) { - msg += " (Do you have an unescaped \"{\" in your template? Use \"{{ '{' }}\") to escape it.)"; - } - var error = new TokenError(msg, this._currentTokenType, span); - this._currentTokenStart = null; - this._currentTokenType = null; - return new _ControlFlowError(error); - }; - _Tokenizer.prototype.handleError = function (e) { - if (e instanceof CursorError) { - e = this._createError(e.msg, this._cursor.getSpan(e.cursor)); - } - if (e instanceof _ControlFlowError) { - this.errors.push(e.error); - } - else { - throw e; - } - }; - _Tokenizer.prototype._attemptCharCode = function (charCode) { - if (this._cursor.peek() === charCode) { - this._cursor.advance(); - return true; - } - return false; - }; - _Tokenizer.prototype._attemptCharCodeCaseInsensitive = function (charCode) { - if (compareCharCodeCaseInsensitive(this._cursor.peek(), charCode)) { - this._cursor.advance(); - return true; - } - return false; - }; - _Tokenizer.prototype._requireCharCode = function (charCode) { - var location = this._cursor.clone(); - if (!this._attemptCharCode(charCode)) { - throw this._createError(_unexpectedCharacterErrorMsg(this._cursor.peek()), this._cursor.getSpan(location)); - } - }; - _Tokenizer.prototype._attemptStr = function (chars) { - var len = chars.length; - if (this._cursor.charsLeft() < len) { - return false; - } - var initialPosition = this._cursor.clone(); - for (var i = 0; i < len; i++) { - if (!this._attemptCharCode(chars.charCodeAt(i))) { - // If attempting to parse the string fails, we want to reset the parser - // to where it was before the attempt - this._cursor = initialPosition; - return false; - } - } - return true; - }; - _Tokenizer.prototype._attemptStrCaseInsensitive = function (chars) { - for (var i = 0; i < chars.length; i++) { - if (!this._attemptCharCodeCaseInsensitive(chars.charCodeAt(i))) { - return false; - } - } - return true; - }; - _Tokenizer.prototype._requireStr = function (chars) { - var location = this._cursor.clone(); - if (!this._attemptStr(chars)) { - throw this._createError(_unexpectedCharacterErrorMsg(this._cursor.peek()), this._cursor.getSpan(location)); - } - }; - _Tokenizer.prototype._attemptCharCodeUntilFn = function (predicate) { - while (!predicate(this._cursor.peek())) { - this._cursor.advance(); - } - }; - _Tokenizer.prototype._requireCharCodeUntilFn = function (predicate, len) { - var start = this._cursor.clone(); - this._attemptCharCodeUntilFn(predicate); - var end = this._cursor.clone(); - if (end.diff(start) < len) { - throw this._createError(_unexpectedCharacterErrorMsg(this._cursor.peek()), this._cursor.getSpan(start)); - } - }; - _Tokenizer.prototype._attemptUntilChar = function (char) { - while (this._cursor.peek() !== char) { - this._cursor.advance(); - } - }; - _Tokenizer.prototype._readChar = function (decodeEntities) { - if (decodeEntities && this._cursor.peek() === $AMPERSAND) { - return this._decodeEntity(); - } - else { - // Don't rely upon reading directly from `_input` as the actual char value - // may have been generated from an escape sequence. - var char = String.fromCodePoint(this._cursor.peek()); - this._cursor.advance(); - return char; - } - }; - _Tokenizer.prototype._decodeEntity = function () { - var start = this._cursor.clone(); - this._cursor.advance(); - if (this._attemptCharCode($HASH)) { - var isHex = this._attemptCharCode($x) || this._attemptCharCode($X); - var codeStart = this._cursor.clone(); - this._attemptCharCodeUntilFn(isDigitEntityEnd); - if (this._cursor.peek() != $SEMICOLON) { - throw this._createError(_unexpectedCharacterErrorMsg(this._cursor.peek()), this._cursor.getSpan()); - } - var strNum = this._cursor.getChars(codeStart); - this._cursor.advance(); - try { - var charCode = parseInt(strNum, isHex ? 16 : 10); - return String.fromCharCode(charCode); - } - catch (_a) { - throw this._createError(_unknownEntityErrorMsg(this._cursor.getChars(start)), this._cursor.getSpan()); - } - } - else { - var nameStart = this._cursor.clone(); - this._attemptCharCodeUntilFn(isNamedEntityEnd); - if (this._cursor.peek() != $SEMICOLON) { - this._cursor = nameStart; - return '&'; - } - var name_1 = this._cursor.getChars(nameStart); - this._cursor.advance(); - var char = NAMED_ENTITIES[name_1]; - if (!char) { - throw this._createError(_unknownEntityErrorMsg(name_1), this._cursor.getSpan(start)); - } - return char; - } - }; - _Tokenizer.prototype._consumeRawText = function (decodeEntities, endMarkerPredicate) { - this._beginToken(decodeEntities ? TokenType.ESCAPABLE_RAW_TEXT : TokenType.RAW_TEXT); - var parts = []; - while (true) { - var tagCloseStart = this._cursor.clone(); - var foundEndMarker = endMarkerPredicate(); - this._cursor = tagCloseStart; - if (foundEndMarker) { - break; - } - parts.push(this._readChar(decodeEntities)); - } - return this._endToken([this._processCarriageReturns(parts.join(''))]); - }; - _Tokenizer.prototype._consumeComment = function (start) { - var _this = this; - this._beginToken(TokenType.COMMENT_START, start); - this._requireCharCode($MINUS); - this._endToken([]); - this._consumeRawText(false, function () { return _this._attemptStr('-->'); }); - this._beginToken(TokenType.COMMENT_END); - this._requireStr('-->'); - this._endToken([]); - }; - _Tokenizer.prototype._consumeCdata = function (start) { - var _this = this; - this._beginToken(TokenType.CDATA_START, start); - this._requireStr('CDATA['); - this._endToken([]); - this._consumeRawText(false, function () { return _this._attemptStr(']]>'); }); - this._beginToken(TokenType.CDATA_END); - this._requireStr(']]>'); - this._endToken([]); - }; - _Tokenizer.prototype._consumeDocType = function (start) { - this._beginToken(TokenType.DOC_TYPE, start); - var contentStart = this._cursor.clone(); - this._attemptUntilChar($GT); - var content = this._cursor.getChars(contentStart); - this._cursor.advance(); - this._endToken([content]); - }; - _Tokenizer.prototype._consumePrefixAndName = function () { - var nameOrPrefixStart = this._cursor.clone(); - var prefix = ''; - while (this._cursor.peek() !== $COLON && !isPrefixEnd(this._cursor.peek())) { - this._cursor.advance(); - } - var nameStart; - if (this._cursor.peek() === $COLON) { - prefix = this._cursor.getChars(nameOrPrefixStart); - this._cursor.advance(); - nameStart = this._cursor.clone(); - } - else { - nameStart = nameOrPrefixStart; - } - this._requireCharCodeUntilFn(isNameEnd, prefix === '' ? 0 : 1); - var name = this._cursor.getChars(nameStart); - return [prefix, name]; - }; - _Tokenizer.prototype._consumeTagOpen = function (start) { - var tagName; - var prefix; - var openTagToken; - var tokensBeforeTagOpen = this.tokens.length; - var innerStart = this._cursor.clone(); - try { - if (!isAsciiLetter(this._cursor.peek())) { - throw this._createError(_unexpectedCharacterErrorMsg(this._cursor.peek()), this._cursor.getSpan(start)); - } - openTagToken = this._consumeTagOpenStart(start); - prefix = openTagToken.parts[0]; - tagName = openTagToken.parts[1]; - this._attemptCharCodeUntilFn(isNotWhitespace); - while (this._cursor.peek() !== $SLASH && this._cursor.peek() !== $GT) { - this._consumeAttributeName(); - this._attemptCharCodeUntilFn(isNotWhitespace); - if (this._attemptCharCode($EQ)) { - this._attemptCharCodeUntilFn(isNotWhitespace); - this._consumeAttributeValue(); - } - this._attemptCharCodeUntilFn(isNotWhitespace); - } - this._consumeTagOpenEnd(); - } - catch (e) { - if (e instanceof _ControlFlowError) { - // When the start tag is invalid (including invalid "attributes"), assume we want a "<" - this._cursor = innerStart; - if (openTagToken) { - this.tokens.length = tokensBeforeTagOpen; - } - // Back to back text tokens are merged at the end - this._beginToken(TokenType.TEXT, start); - this._endToken(['<']); - return; - } - throw e; - } - var contentTokenType = this._getTagDefinition(tagName).contentType; - if (contentTokenType === TagContentType.RAW_TEXT) { - this._consumeRawTextWithTagClose(prefix, tagName, false); - } - else if (contentTokenType === TagContentType.ESCAPABLE_RAW_TEXT) { - this._consumeRawTextWithTagClose(prefix, tagName, true); - } - }; - _Tokenizer.prototype._consumeRawTextWithTagClose = function (prefix, tagName, decodeEntities) { - var _this = this; - var textToken = this._consumeRawText(decodeEntities, function () { - if (!_this._attemptCharCode($LT)) - return false; - if (!_this._attemptCharCode($SLASH)) - return false; - _this._attemptCharCodeUntilFn(isNotWhitespace); - if (!_this._attemptStrCaseInsensitive(tagName)) - return false; - _this._attemptCharCodeUntilFn(isNotWhitespace); - return _this._attemptCharCode($GT); - }); - this._beginToken(TokenType.TAG_CLOSE); - this._requireCharCodeUntilFn(function (code) { return code === $GT; }, 3); - this._cursor.advance(); // Consume the `>` - this._endToken([prefix, tagName]); - }; - _Tokenizer.prototype._consumeTagOpenStart = function (start) { - this._beginToken(TokenType.TAG_OPEN_START, start); - var parts = this._consumePrefixAndName(); - return this._endToken(parts); - }; - _Tokenizer.prototype._consumeAttributeName = function () { - var attrNameStart = this._cursor.peek(); - if (attrNameStart === $SQ || attrNameStart === $DQ) { - throw this._createError(_unexpectedCharacterErrorMsg(attrNameStart), this._cursor.getSpan()); - } - this._beginToken(TokenType.ATTR_NAME); - var prefixAndName = this._consumePrefixAndName(); - this._endToken(prefixAndName); - }; - _Tokenizer.prototype._consumeAttributeValue = function () { - var value; - if (this._cursor.peek() === $SQ || this._cursor.peek() === $DQ) { - this._beginToken(TokenType.ATTR_QUOTE); - var quoteChar = this._cursor.peek(); - this._cursor.advance(); - this._endToken([String.fromCodePoint(quoteChar)]); - this._beginToken(TokenType.ATTR_VALUE); - var parts = []; - while (this._cursor.peek() !== quoteChar) { - parts.push(this._readChar(true)); - } - value = parts.join(''); - this._endToken([this._processCarriageReturns(value)]); - this._beginToken(TokenType.ATTR_QUOTE); - this._cursor.advance(); - this._endToken([String.fromCodePoint(quoteChar)]); - } - else { - this._beginToken(TokenType.ATTR_VALUE); - var valueStart = this._cursor.clone(); - this._requireCharCodeUntilFn(isNameEnd, 1); - value = this._cursor.getChars(valueStart); - this._endToken([this._processCarriageReturns(value)]); - } - }; - _Tokenizer.prototype._consumeTagOpenEnd = function () { - var tokenType = this._attemptCharCode($SLASH) ? TokenType.TAG_OPEN_END_VOID : TokenType.TAG_OPEN_END; - this._beginToken(tokenType); - this._requireCharCode($GT); - this._endToken([]); - }; - _Tokenizer.prototype._consumeTagClose = function (start) { - this._beginToken(TokenType.TAG_CLOSE, start); - this._attemptCharCodeUntilFn(isNotWhitespace); - var prefixAndName = this._consumePrefixAndName(); - this._attemptCharCodeUntilFn(isNotWhitespace); - this._requireCharCode($GT); - this._endToken(prefixAndName); - }; - _Tokenizer.prototype._consumeExpansionFormStart = function () { - this._beginToken(TokenType.EXPANSION_FORM_START); - this._requireCharCode($LBRACE); - this._endToken([]); - this._expansionCaseStack.push(TokenType.EXPANSION_FORM_START); - this._beginToken(TokenType.RAW_TEXT); - var condition = this._readUntil($COMMA); - this._endToken([condition]); - this._requireCharCode($COMMA); - this._attemptCharCodeUntilFn(isNotWhitespace); - this._beginToken(TokenType.RAW_TEXT); - var type = this._readUntil($COMMA); - this._endToken([type]); - this._requireCharCode($COMMA); - this._attemptCharCodeUntilFn(isNotWhitespace); - }; - _Tokenizer.prototype._consumeExpansionCaseStart = function () { - this._beginToken(TokenType.EXPANSION_CASE_VALUE); - var value = this._readUntil($LBRACE).trim(); - this._endToken([value]); - this._attemptCharCodeUntilFn(isNotWhitespace); - this._beginToken(TokenType.EXPANSION_CASE_EXP_START); - this._requireCharCode($LBRACE); - this._endToken([]); - this._attemptCharCodeUntilFn(isNotWhitespace); - this._expansionCaseStack.push(TokenType.EXPANSION_CASE_EXP_START); - }; - _Tokenizer.prototype._consumeExpansionCaseEnd = function () { - this._beginToken(TokenType.EXPANSION_CASE_EXP_END); - this._requireCharCode($RBRACE); - this._endToken([]); - this._attemptCharCodeUntilFn(isNotWhitespace); - this._expansionCaseStack.pop(); - }; - _Tokenizer.prototype._consumeExpansionFormEnd = function () { - this._beginToken(TokenType.EXPANSION_FORM_END); - this._requireCharCode($RBRACE); - this._endToken([]); - this._expansionCaseStack.pop(); - }; - _Tokenizer.prototype._consumeText = function () { - var start = this._cursor.clone(); - this._beginToken(TokenType.TEXT, start); - var parts = []; - do { - if (this._interpolationConfig && this._attemptStr(this._interpolationConfig.start)) { - parts.push(this._interpolationConfig.start); - this._inInterpolation = true; - } - else if (this._interpolationConfig && this._inInterpolation && - this._attemptStr(this._interpolationConfig.end)) { - parts.push(this._interpolationConfig.end); - this._inInterpolation = false; - } - else { - parts.push(this._readChar(true)); - } - } while (!this._isTextEnd()); - this._endToken([this._processCarriageReturns(parts.join(''))]); - }; - _Tokenizer.prototype._isTextEnd = function () { - if (this._cursor.peek() === $LT || this._cursor.peek() === $EOF) { - return true; - } - if (this._tokenizeIcu && !this._inInterpolation) { - if (this.isExpansionFormStart()) { - // start of an expansion form - return true; - } - if (this._cursor.peek() === $RBRACE && this._isInExpansionCase()) { - // end of and expansion case - return true; - } - } - return false; - }; - _Tokenizer.prototype._readUntil = function (char) { - var start = this._cursor.clone(); - this._attemptUntilChar(char); - return this._cursor.getChars(start); - }; - _Tokenizer.prototype._isInExpansionCase = function () { - return this._expansionCaseStack.length > 0 && - this._expansionCaseStack[this._expansionCaseStack.length - 1] === - TokenType.EXPANSION_CASE_EXP_START; - }; - _Tokenizer.prototype._isInExpansionForm = function () { - return this._expansionCaseStack.length > 0 && - this._expansionCaseStack[this._expansionCaseStack.length - 1] === - TokenType.EXPANSION_FORM_START; - }; - _Tokenizer.prototype.isExpansionFormStart = function () { - if (this._cursor.peek() !== $LBRACE) { - return false; - } - if (this._interpolationConfig) { - var start = this._cursor.clone(); - var isInterpolation = this._attemptStr(this._interpolationConfig.start); - this._cursor = start; - return !isInterpolation; - } - return true; - }; - return _Tokenizer; -}()); -function isNotWhitespace(code) { - return !isWhitespace(code) || code === $EOF; -} -function isNameEnd(code) { - return isWhitespace(code) || code === $GT || code === $SLASH || - code === $SQ || code === $DQ || code === $EQ; -} -function isPrefixEnd(code) { - return (code < $a || $z < code) && (code < $A || $Z < code) && - (code < $0 || code > $9); -} -function isDigitEntityEnd(code) { - return code == $SEMICOLON || code == $EOF || !isAsciiHexDigit(code); -} -function isNamedEntityEnd(code) { - return code == $SEMICOLON || code == $EOF || !isAsciiLetter(code); -} -function isExpansionCaseStart(peek) { - return peek === $EQ || isAsciiLetter(peek) || isDigit(peek); -} -function compareCharCodeCaseInsensitive(code1, code2) { - return toUpperCaseCharCode(code1) == toUpperCaseCharCode(code2); -} -function toUpperCaseCharCode(code) { - return code >= $a && code <= $z ? code - $a + $A : code; -} -function mergeTextTokens(srcTokens) { - var dstTokens = []; - var lastDstToken = undefined; - for (var i = 0; i < srcTokens.length; i++) { - var token = srcTokens[i]; - if (lastDstToken && lastDstToken.type == TokenType.TEXT && token.type == TokenType.TEXT) { - lastDstToken.parts[0] += token.parts[0]; - lastDstToken.sourceSpan.end = token.sourceSpan.end; - } - else { - lastDstToken = token; - dstTokens.push(lastDstToken); - } - } - return dstTokens; -} -var PlainCharacterCursor = /** @class */ (function () { - function PlainCharacterCursor(fileOrCursor, range) { - if (fileOrCursor instanceof PlainCharacterCursor) { - this.file = fileOrCursor.file; - this.input = fileOrCursor.input; - this.end = fileOrCursor.end; - this.state = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, fileOrCursor.state); - } - else { - if (!range) { - throw new Error('Programming error: the range argument must be provided with a file argument.'); - } - this.file = fileOrCursor; - this.input = fileOrCursor.content; - this.end = range.endPos; - this.state = { - peek: -1, - offset: range.startPos, - line: range.startLine, - column: range.startCol, - }; - } - } - PlainCharacterCursor.prototype.clone = function () { return new PlainCharacterCursor(this); }; - PlainCharacterCursor.prototype.peek = function () { return this.state.peek; }; - PlainCharacterCursor.prototype.charsLeft = function () { return this.end - this.state.offset; }; - PlainCharacterCursor.prototype.diff = function (other) { return this.state.offset - other.state.offset; }; - PlainCharacterCursor.prototype.advance = function () { this.advanceState(this.state); }; - PlainCharacterCursor.prototype.init = function () { this.updatePeek(this.state); }; - PlainCharacterCursor.prototype.getSpan = function (start, leadingTriviaCodePoints) { - start = start || this; - if (leadingTriviaCodePoints) { - start = start.clone(); - while (this.diff(start) > 0 && leadingTriviaCodePoints.indexOf(start.peek()) !== -1) { - start.advance(); - } - } - return new ParseSourceSpan(new ParseLocation(start.file, start.state.offset, start.state.line, start.state.column), new ParseLocation(this.file, this.state.offset, this.state.line, this.state.column)); - }; - PlainCharacterCursor.prototype.getChars = function (start) { - return this.input.substring(start.state.offset, this.state.offset); - }; - PlainCharacterCursor.prototype.charAt = function (pos) { return this.input.charCodeAt(pos); }; - PlainCharacterCursor.prototype.advanceState = function (state) { - if (state.offset >= this.end) { - this.state = state; - throw new CursorError('Unexpected character "EOF"', this); - } - var currentChar = this.charAt(state.offset); - if (currentChar === $LF) { - state.line++; - state.column = 0; - } - else if (!isNewLine(currentChar)) { - state.column++; - } - state.offset++; - this.updatePeek(state); - }; - PlainCharacterCursor.prototype.updatePeek = function (state) { - state.peek = state.offset >= this.end ? $EOF : this.charAt(state.offset); - }; - return PlainCharacterCursor; -}()); -var EscapedCharacterCursor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(EscapedCharacterCursor, _super); - function EscapedCharacterCursor(fileOrCursor, range) { - var _this = this; - if (fileOrCursor instanceof EscapedCharacterCursor) { - _this = _super.call(this, fileOrCursor) || this; - _this.internalState = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, fileOrCursor.internalState); - } - else { - _this = _super.call(this, fileOrCursor, range) || this; - _this.internalState = _this.state; - } - return _this; - } - EscapedCharacterCursor.prototype.advance = function () { - this.state = this.internalState; - _super.prototype.advance.call(this); - this.processEscapeSequence(); - }; - EscapedCharacterCursor.prototype.init = function () { - _super.prototype.init.call(this); - this.processEscapeSequence(); - }; - EscapedCharacterCursor.prototype.clone = function () { return new EscapedCharacterCursor(this); }; - EscapedCharacterCursor.prototype.getChars = function (start) { - var cursor = start.clone(); - var chars = ''; - while (cursor.internalState.offset < this.internalState.offset) { - chars += String.fromCodePoint(cursor.peek()); - cursor.advance(); - } - return chars; - }; - /** - * Process the escape sequence that starts at the current position in the text. - * - * This method is called to ensure that `peek` has the unescaped value of escape sequences. - */ - EscapedCharacterCursor.prototype.processEscapeSequence = function () { - var _this = this; - var peek = function () { return _this.internalState.peek; }; - if (peek() === $BACKSLASH) { - // We have hit an escape sequence so we need the internal state to become independent - // of the external state. - this.internalState = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"])({}, this.state); - // Move past the backslash - this.advanceState(this.internalState); - // First check for standard control char sequences - if (peek() === $n) { - this.state.peek = $LF; - } - else if (peek() === $r) { - this.state.peek = $CR; - } - else if (peek() === $v) { - this.state.peek = $VTAB; - } - else if (peek() === $t) { - this.state.peek = $TAB; - } - else if (peek() === $b) { - this.state.peek = $BSPACE; - } - else if (peek() === $f) { - this.state.peek = $FF; - } - // Now consider more complex sequences - else if (peek() === $u) { - // Unicode code-point sequence - this.advanceState(this.internalState); // advance past the `u` char - if (peek() === $LBRACE) { - // Variable length Unicode, e.g. `\x{123}` - this.advanceState(this.internalState); // advance past the `{` char - // Advance past the variable number of hex digits until we hit a `}` char - var digitStart = this.clone(); - var length_1 = 0; - while (peek() !== $RBRACE) { - this.advanceState(this.internalState); - length_1++; - } - this.state.peek = this.decodeHexDigits(digitStart, length_1); - } - else { - // Fixed length Unicode, e.g. `\u1234` - var digitStart = this.clone(); - this.advanceState(this.internalState); - this.advanceState(this.internalState); - this.advanceState(this.internalState); - this.state.peek = this.decodeHexDigits(digitStart, 4); - } - } - else if (peek() === $x) { - // Hex char code, e.g. `\x2F` - this.advanceState(this.internalState); // advance past the `x` char - var digitStart = this.clone(); - this.advanceState(this.internalState); - this.state.peek = this.decodeHexDigits(digitStart, 2); - } - else if (isOctalDigit(peek())) { - // Octal char code, e.g. `\012`, - var octal = ''; - var length_2 = 0; - var previous = this.clone(); - while (isOctalDigit(peek()) && length_2 < 3) { - previous = this.clone(); - octal += String.fromCodePoint(peek()); - this.advanceState(this.internalState); - length_2++; - } - this.state.peek = parseInt(octal, 8); - // Backup one char - this.internalState = previous.internalState; - } - else if (isNewLine(this.internalState.peek)) { - // Line continuation `\` followed by a new line - this.advanceState(this.internalState); // advance over the newline - this.state = this.internalState; - } - else { - // If none of the `if` blocks were executed then we just have an escaped normal character. - // In that case we just, effectively, skip the backslash from the character. - this.state.peek = this.internalState.peek; - } - } - }; - EscapedCharacterCursor.prototype.decodeHexDigits = function (start, length) { - var hex = this.input.substr(start.internalState.offset, length); - var charCode = parseInt(hex, 16); - if (!isNaN(charCode)) { - return charCode; - } - else { - start.state = start.internalState; - throw new CursorError('Invalid hexadecimal escape sequence', start); - } - }; - return EscapedCharacterCursor; -}(PlainCharacterCursor)); -var CursorError = /** @class */ (function () { - function CursorError(msg, cursor) { - this.msg = msg; - this.cursor = cursor; - } - return CursorError; -}()); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var TreeError = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(TreeError, _super); - function TreeError(elementName, span, msg) { - var _this = _super.call(this, span, msg) || this; - _this.elementName = elementName; - return _this; - } - TreeError.create = function (elementName, span, msg) { - return new TreeError(elementName, span, msg); - }; - return TreeError; -}(ParseError)); -var ParseTreeResult = /** @class */ (function () { - function ParseTreeResult(rootNodes, errors) { - this.rootNodes = rootNodes; - this.errors = errors; - } - return ParseTreeResult; -}()); -var Parser = /** @class */ (function () { - function Parser(getTagDefinition) { - this.getTagDefinition = getTagDefinition; - } - Parser.prototype.parse = function (source, url, options) { - var tokensAndErrors = tokenize(source, url, this.getTagDefinition, options); - var treeAndErrors = new _TreeBuilder(tokensAndErrors.tokens, this.getTagDefinition).build(); - return new ParseTreeResult(treeAndErrors.rootNodes, tokensAndErrors.errors.concat(treeAndErrors.errors)); - }; - return Parser; -}()); -var _TreeBuilder = /** @class */ (function () { - function _TreeBuilder(tokens, getTagDefinition) { - this.tokens = tokens; - this.getTagDefinition = getTagDefinition; - this._index = -1; - this._rootNodes = []; - this._errors = []; - this._elementStack = []; - this._advance(); - } - _TreeBuilder.prototype.build = function () { - while (this._peek.type !== TokenType.EOF) { - if (this._peek.type === TokenType.TAG_OPEN_START) { - this._consumeStartTag(this._advance()); - } - else if (this._peek.type === TokenType.TAG_CLOSE) { - this._consumeEndTag(this._advance()); - } - else if (this._peek.type === TokenType.CDATA_START) { - this._closeVoidElement(); - this._consumeCdata(this._advance()); - } - else if (this._peek.type === TokenType.COMMENT_START) { - this._closeVoidElement(); - this._consumeComment(this._advance()); - } - else if (this._peek.type === TokenType.TEXT || this._peek.type === TokenType.RAW_TEXT || - this._peek.type === TokenType.ESCAPABLE_RAW_TEXT) { - this._closeVoidElement(); - this._consumeText(this._advance()); - } - else if (this._peek.type === TokenType.EXPANSION_FORM_START) { - this._consumeExpansion(this._advance()); - } - else { - // Skip all other tokens... - this._advance(); - } - } - return new ParseTreeResult(this._rootNodes, this._errors); - }; - _TreeBuilder.prototype._advance = function () { - var prev = this._peek; - if (this._index < this.tokens.length - 1) { - // Note: there is always an EOF token at the end - this._index++; - } - this._peek = this.tokens[this._index]; - return prev; - }; - _TreeBuilder.prototype._advanceIf = function (type) { - if (this._peek.type === type) { - return this._advance(); - } - return null; - }; - _TreeBuilder.prototype._consumeCdata = function (startToken) { - this._consumeText(this._advance()); - this._advanceIf(TokenType.CDATA_END); - }; - _TreeBuilder.prototype._consumeComment = function (token) { - var text = this._advanceIf(TokenType.RAW_TEXT); - this._advanceIf(TokenType.COMMENT_END); - var value = text != null ? text.parts[0].trim() : null; - this._addToParent(new Comment(value, token.sourceSpan)); - }; - _TreeBuilder.prototype._consumeExpansion = function (token) { - var switchValue = this._advance(); - var type = this._advance(); - var cases = []; - // read = - while (this._peek.type === TokenType.EXPANSION_CASE_VALUE) { - var expCase = this._parseExpansionCase(); - if (!expCase) - return; // error - cases.push(expCase); - } - // read the final } - if (this._peek.type !== TokenType.EXPANSION_FORM_END) { - this._errors.push(TreeError.create(null, this._peek.sourceSpan, "Invalid ICU message. Missing '}'.")); - return; - } - var sourceSpan = new ParseSourceSpan(token.sourceSpan.start, this._peek.sourceSpan.end); - this._addToParent(new Expansion(switchValue.parts[0], type.parts[0], cases, sourceSpan, switchValue.sourceSpan)); - this._advance(); - }; - _TreeBuilder.prototype._parseExpansionCase = function () { - var value = this._advance(); - // read { - if (this._peek.type !== TokenType.EXPANSION_CASE_EXP_START) { - this._errors.push(TreeError.create(null, this._peek.sourceSpan, "Invalid ICU message. Missing '{'.")); - return null; - } - // read until } - var start = this._advance(); - var exp = this._collectExpansionExpTokens(start); - if (!exp) - return null; - var end = this._advance(); - exp.push(new Token(TokenType.EOF, [], end.sourceSpan)); - // parse everything in between { and } - var parsedExp = new _TreeBuilder(exp, this.getTagDefinition).build(); - if (parsedExp.errors.length > 0) { - this._errors = this._errors.concat(parsedExp.errors); - return null; - } - var sourceSpan = new ParseSourceSpan(value.sourceSpan.start, end.sourceSpan.end); - var expSourceSpan = new ParseSourceSpan(start.sourceSpan.start, end.sourceSpan.end); - return new ExpansionCase(value.parts[0], parsedExp.rootNodes, sourceSpan, value.sourceSpan, expSourceSpan); - }; - _TreeBuilder.prototype._collectExpansionExpTokens = function (start) { - var exp = []; - var expansionFormStack = [TokenType.EXPANSION_CASE_EXP_START]; - while (true) { - if (this._peek.type === TokenType.EXPANSION_FORM_START || - this._peek.type === TokenType.EXPANSION_CASE_EXP_START) { - expansionFormStack.push(this._peek.type); - } - if (this._peek.type === TokenType.EXPANSION_CASE_EXP_END) { - if (lastOnStack(expansionFormStack, TokenType.EXPANSION_CASE_EXP_START)) { - expansionFormStack.pop(); - if (expansionFormStack.length == 0) - return exp; - } - else { - this._errors.push(TreeError.create(null, start.sourceSpan, "Invalid ICU message. Missing '}'.")); - return null; - } - } - if (this._peek.type === TokenType.EXPANSION_FORM_END) { - if (lastOnStack(expansionFormStack, TokenType.EXPANSION_FORM_START)) { - expansionFormStack.pop(); - } - else { - this._errors.push(TreeError.create(null, start.sourceSpan, "Invalid ICU message. Missing '}'.")); - return null; - } - } - if (this._peek.type === TokenType.EOF) { - this._errors.push(TreeError.create(null, start.sourceSpan, "Invalid ICU message. Missing '}'.")); - return null; - } - exp.push(this._advance()); - } - }; - _TreeBuilder.prototype._consumeText = function (token) { - var text = token.parts[0]; - if (text.length > 0 && text[0] == '\n') { - var parent_1 = this._getParentElement(); - if (parent_1 != null && parent_1.children.length == 0 && - this.getTagDefinition(parent_1.name).ignoreFirstLf) { - text = text.substring(1); - } - } - if (text.length > 0) { - this._addToParent(new Text$3(text, token.sourceSpan)); - } - }; - _TreeBuilder.prototype._closeVoidElement = function () { - var el = this._getParentElement(); - if (el && this.getTagDefinition(el.name).isVoid) { - this._elementStack.pop(); - } - }; - _TreeBuilder.prototype._consumeStartTag = function (startTagToken) { - var prefix = startTagToken.parts[0]; - var name = startTagToken.parts[1]; - var attrs = []; - while (this._peek.type === TokenType.ATTR_NAME) { - attrs.push(this._consumeAttr(this._advance())); - } - var fullName = this._getElementFullName(prefix, name, this._getParentElement()); - var selfClosing = false; - // Note: There could have been a tokenizer error - // so that we don't get a token for the end tag... - if (this._peek.type === TokenType.TAG_OPEN_END_VOID) { - this._advance(); - selfClosing = true; - var tagDef = this.getTagDefinition(fullName); - if (!(tagDef.canSelfClose || getNsPrefix(fullName) !== null || tagDef.isVoid)) { - this._errors.push(TreeError.create(fullName, startTagToken.sourceSpan, "Only void and foreign elements can be self closed \"" + startTagToken.parts[1] + "\"")); - } - } - else if (this._peek.type === TokenType.TAG_OPEN_END) { - this._advance(); - selfClosing = false; - } - var end = this._peek.sourceSpan.start; - var span = new ParseSourceSpan(startTagToken.sourceSpan.start, end); - var el = new Element$1(fullName, attrs, [], span, span, undefined); - this._pushElement(el); - if (selfClosing) { - this._popElement(fullName); - el.endSourceSpan = span; - } - }; - _TreeBuilder.prototype._pushElement = function (el) { - var parentEl = this._getParentElement(); - if (parentEl && this.getTagDefinition(parentEl.name).isClosedByChild(el.name)) { - this._elementStack.pop(); - } - this._addToParent(el); - this._elementStack.push(el); - }; - _TreeBuilder.prototype._consumeEndTag = function (endTagToken) { - var fullName = this._getElementFullName(endTagToken.parts[0], endTagToken.parts[1], this._getParentElement()); - if (this._getParentElement()) { - this._getParentElement().endSourceSpan = endTagToken.sourceSpan; - } - if (this.getTagDefinition(fullName).isVoid) { - this._errors.push(TreeError.create(fullName, endTagToken.sourceSpan, "Void elements do not have end tags \"" + endTagToken.parts[1] + "\"")); - } - else if (!this._popElement(fullName)) { - var errMsg = "Unexpected closing tag \"" + fullName + "\". It may happen when the tag has already been closed by another tag. For more info see https://www.w3.org/TR/html5/syntax.html#closing-elements-that-have-implied-end-tags"; - this._errors.push(TreeError.create(fullName, endTagToken.sourceSpan, errMsg)); - } - }; - _TreeBuilder.prototype._popElement = function (fullName) { - for (var stackIndex = this._elementStack.length - 1; stackIndex >= 0; stackIndex--) { - var el = this._elementStack[stackIndex]; - if (el.name == fullName) { - this._elementStack.splice(stackIndex, this._elementStack.length - stackIndex); - return true; - } - if (!this.getTagDefinition(el.name).closedByParent) { - return false; - } - } - return false; - }; - _TreeBuilder.prototype._consumeAttr = function (attrName) { - var fullName = mergeNsAndName(attrName.parts[0], attrName.parts[1]); - var end = attrName.sourceSpan.end; - var value = ''; - var valueSpan = undefined; - if (this._peek.type === TokenType.ATTR_QUOTE) { - this._advance(); - } - if (this._peek.type === TokenType.ATTR_VALUE) { - var valueToken = this._advance(); - value = valueToken.parts[0]; - end = valueToken.sourceSpan.end; - valueSpan = valueToken.sourceSpan; - } - if (this._peek.type === TokenType.ATTR_QUOTE) { - var quoteToken = this._advance(); - end = quoteToken.sourceSpan.end; - } - return new Attribute(fullName, value, new ParseSourceSpan(attrName.sourceSpan.start, end), valueSpan); - }; - _TreeBuilder.prototype._getParentElement = function () { - return this._elementStack.length > 0 ? this._elementStack[this._elementStack.length - 1] : null; - }; - /** - * Returns the parent in the DOM and the container. - * - * `` elements are skipped as they are not rendered as DOM element. - */ - _TreeBuilder.prototype._getParentElementSkippingContainers = function () { - var container = null; - for (var i = this._elementStack.length - 1; i >= 0; i--) { - if (!isNgContainer(this._elementStack[i].name)) { - return { parent: this._elementStack[i], container: container }; - } - container = this._elementStack[i]; - } - return { parent: null, container: container }; - }; - _TreeBuilder.prototype._addToParent = function (node) { - var parent = this._getParentElement(); - if (parent != null) { - parent.children.push(node); - } - else { - this._rootNodes.push(node); - } - }; - /** - * Insert a node between the parent and the container. - * When no container is given, the node is appended as a child of the parent. - * Also updates the element stack accordingly. - * - * @internal - */ - _TreeBuilder.prototype._insertBeforeContainer = function (parent, container, node) { - if (!container) { - this._addToParent(node); - this._elementStack.push(node); - } - else { - if (parent) { - // replace the container with the new node in the children - var index = parent.children.indexOf(container); - parent.children[index] = node; - } - else { - this._rootNodes.push(node); - } - node.children.push(container); - this._elementStack.splice(this._elementStack.indexOf(container), 0, node); - } - }; - _TreeBuilder.prototype._getElementFullName = function (prefix, localName, parentElement) { - if (prefix === '') { - prefix = this.getTagDefinition(localName).implicitNamespacePrefix || ''; - if (prefix === '' && parentElement != null) { - prefix = getNsPrefix(parentElement.name); - } - } - return mergeNsAndName(prefix, localName); - }; - return _TreeBuilder; -}()); -function lastOnStack(stack, element) { - return stack.length > 0 && stack[stack.length - 1] === element; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var HtmlParser = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(HtmlParser, _super); - function HtmlParser() { - return _super.call(this, getHtmlTagDefinition) || this; - } - HtmlParser.prototype.parse = function (source, url, options) { - return _super.prototype.parse.call(this, source, url, options); - }; - return HtmlParser; -}(Parser)); - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var PRESERVE_WS_ATTR_NAME = 'ngPreserveWhitespaces'; -var SKIP_WS_TRIM_TAGS = new Set(['pre', 'template', 'textarea', 'script', 'style']); -// Equivalent to \s with \u00a0 (non-breaking space) excluded. -// Based on https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp -var WS_CHARS = ' \f\n\r\t\v\u1680\u180e\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff'; -var NO_WS_REGEXP = new RegExp("[^" + WS_CHARS + "]"); -var WS_REPLACE_REGEXP = new RegExp("[" + WS_CHARS + "]{2,}", 'g'); -function hasPreserveWhitespacesAttr(attrs) { - return attrs.some(function (attr) { return attr.name === PRESERVE_WS_ATTR_NAME; }); -} -/** - * Angular Dart introduced &ngsp; as a placeholder for non-removable space, see: - * https://github.com/dart-lang/angular/blob/0bb611387d29d65b5af7f9d2515ab571fd3fbee4/_tests/test/compiler/preserve_whitespace_test.dart#L25-L32 - * In Angular Dart &ngsp; is converted to the 0xE500 PUA (Private Use Areas) unicode character - * and later on replaced by a space. We are re-implementing the same idea here. - */ -function replaceNgsp(value) { - // lexer is replacing the &ngsp; pseudo-entity with NGSP_UNICODE - return value.replace(new RegExp(NGSP_UNICODE, 'g'), ' '); -} -/** - * This visitor can walk HTML parse tree and remove / trim text nodes using the following rules: - * - consider spaces, tabs and new lines as whitespace characters; - * - drop text nodes consisting of whitespace characters only; - * - for all other text nodes replace consecutive whitespace characters with one space; - * - convert &ngsp; pseudo-entity to a single space; - * - * Removal and trimming of whitespaces have positive performance impact (less code to generate - * while compiling templates, faster view creation). At the same time it can be "destructive" - * in some cases (whitespaces can influence layout). Because of the potential of breaking layout - * this visitor is not activated by default in Angular 5 and people need to explicitly opt-in for - * whitespace removal. The default option for whitespace removal will be revisited in Angular 6 - * and might be changed to "on" by default. - */ -var WhitespaceVisitor = /** @class */ (function () { - function WhitespaceVisitor() { - } - WhitespaceVisitor.prototype.visitElement = function (element, context) { - if (SKIP_WS_TRIM_TAGS.has(element.name) || hasPreserveWhitespacesAttr(element.attrs)) { - // don't descent into elements where we need to preserve whitespaces - // but still visit all attributes to eliminate one used as a market to preserve WS - return new Element$1(element.name, visitAll$1(this, element.attrs), element.children, element.sourceSpan, element.startSourceSpan, element.endSourceSpan, element.i18n); - } - return new Element$1(element.name, element.attrs, visitAll$1(this, element.children), element.sourceSpan, element.startSourceSpan, element.endSourceSpan, element.i18n); - }; - WhitespaceVisitor.prototype.visitAttribute = function (attribute, context) { - return attribute.name !== PRESERVE_WS_ATTR_NAME ? attribute : null; - }; - WhitespaceVisitor.prototype.visitText = function (text, context) { - var isNotBlank = text.value.match(NO_WS_REGEXP); - if (isNotBlank) { - return new Text$3(replaceNgsp(text.value).replace(WS_REPLACE_REGEXP, ' '), text.sourceSpan, text.i18n); - } - return null; - }; - WhitespaceVisitor.prototype.visitComment = function (comment, context) { return comment; }; - WhitespaceVisitor.prototype.visitExpansion = function (expansion, context) { return expansion; }; - WhitespaceVisitor.prototype.visitExpansionCase = function (expansionCase, context) { return expansionCase; }; - return WhitespaceVisitor; -}()); -function removeWhitespaces(htmlAstWithErrors) { - return new ParseTreeResult(visitAll$1(new WhitespaceVisitor(), htmlAstWithErrors.rootNodes), htmlAstWithErrors.errors); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -// http://cldr.unicode.org/index/cldr-spec/plural-rules -var PLURAL_CASES = ['zero', 'one', 'two', 'few', 'many', 'other']; -/** - * Expands special forms into elements. - * - * For example, - * - * ``` - * { messages.length, plural, - * =0 {zero} - * =1 {one} - * other {more than one} - * } - * ``` - * - * will be expanded into - * - * ``` - * - * zero - * one - * more than one - * - * ``` - */ -function expandNodes(nodes) { - var expander = new _Expander(); - return new ExpansionResult(visitAll$1(expander, nodes), expander.isExpanded, expander.errors); -} -var ExpansionResult = /** @class */ (function () { - function ExpansionResult(nodes, expanded, errors) { - this.nodes = nodes; - this.expanded = expanded; - this.errors = errors; - } - return ExpansionResult; -}()); -var ExpansionError = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ExpansionError, _super); - function ExpansionError(span, errorMsg) { - return _super.call(this, span, errorMsg) || this; - } - return ExpansionError; -}(ParseError)); -/** - * Expand expansion forms (plural, select) to directives - * - * @internal - */ -var _Expander = /** @class */ (function () { - function _Expander() { - this.isExpanded = false; - this.errors = []; - } - _Expander.prototype.visitElement = function (element, context) { - return new Element$1(element.name, element.attrs, visitAll$1(this, element.children), element.sourceSpan, element.startSourceSpan, element.endSourceSpan); - }; - _Expander.prototype.visitAttribute = function (attribute, context) { return attribute; }; - _Expander.prototype.visitText = function (text, context) { return text; }; - _Expander.prototype.visitComment = function (comment, context) { return comment; }; - _Expander.prototype.visitExpansion = function (icu, context) { - this.isExpanded = true; - return icu.type == 'plural' ? _expandPluralForm(icu, this.errors) : - _expandDefaultForm(icu, this.errors); - }; - _Expander.prototype.visitExpansionCase = function (icuCase, context) { - throw new Error('Should not be reached'); - }; - return _Expander; -}()); -// Plural forms are expanded to `NgPlural` and `NgPluralCase`s -function _expandPluralForm(ast, errors) { - var children = ast.cases.map(function (c) { - if (PLURAL_CASES.indexOf(c.value) == -1 && !c.value.match(/^=\d+$/)) { - errors.push(new ExpansionError(c.valueSourceSpan, "Plural cases should be \"=\" or one of " + PLURAL_CASES.join(", "))); - } - var expansionResult = expandNodes(c.expression); - errors.push.apply(errors, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(expansionResult.errors)); - return new Element$1("ng-template", [new Attribute('ngPluralCase', "" + c.value, c.valueSourceSpan)], expansionResult.nodes, c.sourceSpan, c.sourceSpan, c.sourceSpan); - }); - var switchAttr = new Attribute('[ngPlural]', ast.switchValue, ast.switchValueSourceSpan); - return new Element$1('ng-container', [switchAttr], children, ast.sourceSpan, ast.sourceSpan, ast.sourceSpan); -} -// ICU messages (excluding plural form) are expanded to `NgSwitch` and `NgSwitchCase`s -function _expandDefaultForm(ast, errors) { - var children = ast.cases.map(function (c) { - var expansionResult = expandNodes(c.expression); - errors.push.apply(errors, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(expansionResult.errors)); - if (c.value === 'other') { - // other is the default case when no values match - return new Element$1("ng-template", [new Attribute('ngSwitchDefault', '', c.valueSourceSpan)], expansionResult.nodes, c.sourceSpan, c.sourceSpan, c.sourceSpan); - } - return new Element$1("ng-template", [new Attribute('ngSwitchCase', "" + c.value, c.valueSourceSpan)], expansionResult.nodes, c.sourceSpan, c.sourceSpan, c.sourceSpan); - }); - var switchAttr = new Attribute('[ngSwitch]', ast.switchValue, ast.switchValueSourceSpan); - return new Element$1('ng-container', [switchAttr], children, ast.sourceSpan, ast.sourceSpan, ast.sourceSpan); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var _a; -/** - * A segment of text within the template. - */ -var TextAst = /** @class */ (function () { - function TextAst(value, ngContentIndex, sourceSpan) { - this.value = value; - this.ngContentIndex = ngContentIndex; - this.sourceSpan = sourceSpan; - } - TextAst.prototype.visit = function (visitor, context) { return visitor.visitText(this, context); }; - return TextAst; -}()); -/** - * A bound expression within the text of a template. - */ -var BoundTextAst = /** @class */ (function () { - function BoundTextAst(value, ngContentIndex, sourceSpan) { - this.value = value; - this.ngContentIndex = ngContentIndex; - this.sourceSpan = sourceSpan; - } - BoundTextAst.prototype.visit = function (visitor, context) { - return visitor.visitBoundText(this, context); - }; - return BoundTextAst; -}()); -/** - * A plain attribute on an element. - */ -var AttrAst = /** @class */ (function () { - function AttrAst(name, value, sourceSpan) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - } - AttrAst.prototype.visit = function (visitor, context) { return visitor.visitAttr(this, context); }; - return AttrAst; -}()); -var BoundPropertyMapping = (_a = {}, - _a[4 /* Animation */] = 4 /* Animation */, - _a[1 /* Attribute */] = 1 /* Attribute */, - _a[2 /* Class */] = 2 /* Class */, - _a[0 /* Property */] = 0 /* Property */, - _a[3 /* Style */] = 3 /* Style */, - _a); -/** - * A binding for an element property (e.g. `[property]="expression"`) or an animation trigger (e.g. - * `[@trigger]="stateExp"`) - */ -var BoundElementPropertyAst = /** @class */ (function () { - function BoundElementPropertyAst(name, type, securityContext, value, unit, sourceSpan) { - this.name = name; - this.type = type; - this.securityContext = securityContext; - this.value = value; - this.unit = unit; - this.sourceSpan = sourceSpan; - this.isAnimation = this.type === 4 /* Animation */; - } - BoundElementPropertyAst.fromBoundProperty = function (prop) { - var type = BoundPropertyMapping[prop.type]; - return new BoundElementPropertyAst(prop.name, type, prop.securityContext, prop.value, prop.unit, prop.sourceSpan); - }; - BoundElementPropertyAst.prototype.visit = function (visitor, context) { - return visitor.visitElementProperty(this, context); - }; - return BoundElementPropertyAst; -}()); -/** - * A binding for an element event (e.g. `(event)="handler()"`) or an animation trigger event (e.g. - * `(@trigger.phase)="callback($event)"`). - */ -var BoundEventAst = /** @class */ (function () { - function BoundEventAst(name, target, phase, handler, sourceSpan, handlerSpan) { - this.name = name; - this.target = target; - this.phase = phase; - this.handler = handler; - this.sourceSpan = sourceSpan; - this.handlerSpan = handlerSpan; - this.fullName = BoundEventAst.calcFullName(this.name, this.target, this.phase); - this.isAnimation = !!this.phase; - } - BoundEventAst.calcFullName = function (name, target, phase) { - if (target) { - return target + ":" + name; - } - if (phase) { - return "@" + name + "." + phase; - } - return name; - }; - BoundEventAst.fromParsedEvent = function (event) { - var target = event.type === 0 /* Regular */ ? event.targetOrPhase : null; - var phase = event.type === 1 /* Animation */ ? event.targetOrPhase : null; - return new BoundEventAst(event.name, target, phase, event.handler, event.sourceSpan, event.handlerSpan); - }; - BoundEventAst.prototype.visit = function (visitor, context) { - return visitor.visitEvent(this, context); - }; - return BoundEventAst; -}()); -/** - * A reference declaration on an element (e.g. `let someName="expression"`). - */ -var ReferenceAst = /** @class */ (function () { - function ReferenceAst(name, value, originalValue, sourceSpan) { - this.name = name; - this.value = value; - this.originalValue = originalValue; - this.sourceSpan = sourceSpan; - } - ReferenceAst.prototype.visit = function (visitor, context) { - return visitor.visitReference(this, context); - }; - return ReferenceAst; -}()); -/** - * A variable declaration on a (e.g. `var-someName="someLocalName"`). - */ -var VariableAst = /** @class */ (function () { - function VariableAst(name, value, sourceSpan) { - this.name = name; - this.value = value; - this.sourceSpan = sourceSpan; - } - VariableAst.fromParsedVariable = function (v) { - return new VariableAst(v.name, v.value, v.sourceSpan); - }; - VariableAst.prototype.visit = function (visitor, context) { - return visitor.visitVariable(this, context); - }; - return VariableAst; -}()); -/** - * An element declaration in a template. - */ -var ElementAst = /** @class */ (function () { - function ElementAst(name, attrs, inputs, outputs, references, directives, providers, hasViewContainer, queryMatches, children, ngContentIndex, sourceSpan, endSourceSpan) { - this.name = name; - this.attrs = attrs; - this.inputs = inputs; - this.outputs = outputs; - this.references = references; - this.directives = directives; - this.providers = providers; - this.hasViewContainer = hasViewContainer; - this.queryMatches = queryMatches; - this.children = children; - this.ngContentIndex = ngContentIndex; - this.sourceSpan = sourceSpan; - this.endSourceSpan = endSourceSpan; - } - ElementAst.prototype.visit = function (visitor, context) { - return visitor.visitElement(this, context); - }; - return ElementAst; -}()); -/** - * A `` element included in an Angular template. - */ -var EmbeddedTemplateAst = /** @class */ (function () { - function EmbeddedTemplateAst(attrs, outputs, references, variables, directives, providers, hasViewContainer, queryMatches, children, ngContentIndex, sourceSpan) { - this.attrs = attrs; - this.outputs = outputs; - this.references = references; - this.variables = variables; - this.directives = directives; - this.providers = providers; - this.hasViewContainer = hasViewContainer; - this.queryMatches = queryMatches; - this.children = children; - this.ngContentIndex = ngContentIndex; - this.sourceSpan = sourceSpan; - } - EmbeddedTemplateAst.prototype.visit = function (visitor, context) { - return visitor.visitEmbeddedTemplate(this, context); - }; - return EmbeddedTemplateAst; -}()); -/** - * A directive property with a bound value (e.g. `*ngIf="condition"). - */ -var BoundDirectivePropertyAst = /** @class */ (function () { - function BoundDirectivePropertyAst(directiveName, templateName, value, sourceSpan) { - this.directiveName = directiveName; - this.templateName = templateName; - this.value = value; - this.sourceSpan = sourceSpan; - } - BoundDirectivePropertyAst.prototype.visit = function (visitor, context) { - return visitor.visitDirectiveProperty(this, context); - }; - return BoundDirectivePropertyAst; -}()); -/** - * A directive declared on an element. - */ -var DirectiveAst = /** @class */ (function () { - function DirectiveAst(directive, inputs, hostProperties, hostEvents, contentQueryStartId, sourceSpan) { - this.directive = directive; - this.inputs = inputs; - this.hostProperties = hostProperties; - this.hostEvents = hostEvents; - this.contentQueryStartId = contentQueryStartId; - this.sourceSpan = sourceSpan; - } - DirectiveAst.prototype.visit = function (visitor, context) { - return visitor.visitDirective(this, context); - }; - return DirectiveAst; -}()); -/** - * A provider declared on an element - */ -var ProviderAst = /** @class */ (function () { - function ProviderAst(token, multiProvider, eager, providers, providerType, lifecycleHooks, sourceSpan, isModule) { - this.token = token; - this.multiProvider = multiProvider; - this.eager = eager; - this.providers = providers; - this.providerType = providerType; - this.lifecycleHooks = lifecycleHooks; - this.sourceSpan = sourceSpan; - this.isModule = isModule; - } - ProviderAst.prototype.visit = function (visitor, context) { - // No visit method in the visitor for now... - return null; - }; - return ProviderAst; -}()); -var ProviderAstType; -(function (ProviderAstType) { - ProviderAstType[ProviderAstType["PublicService"] = 0] = "PublicService"; - ProviderAstType[ProviderAstType["PrivateService"] = 1] = "PrivateService"; - ProviderAstType[ProviderAstType["Component"] = 2] = "Component"; - ProviderAstType[ProviderAstType["Directive"] = 3] = "Directive"; - ProviderAstType[ProviderAstType["Builtin"] = 4] = "Builtin"; -})(ProviderAstType || (ProviderAstType = {})); -/** - * Position where content is to be projected (instance of `` in a template). - */ -var NgContentAst = /** @class */ (function () { - function NgContentAst(index, ngContentIndex, sourceSpan) { - this.index = index; - this.ngContentIndex = ngContentIndex; - this.sourceSpan = sourceSpan; - } - NgContentAst.prototype.visit = function (visitor, context) { - return visitor.visitNgContent(this, context); - }; - return NgContentAst; -}()); -/** - * A visitor that accepts each node but doesn't do anything. It is intended to be used - * as the base class for a visitor that is only interested in a subset of the node types. - */ -var NullTemplateVisitor = /** @class */ (function () { - function NullTemplateVisitor() { - } - NullTemplateVisitor.prototype.visitNgContent = function (ast, context) { }; - NullTemplateVisitor.prototype.visitEmbeddedTemplate = function (ast, context) { }; - NullTemplateVisitor.prototype.visitElement = function (ast, context) { }; - NullTemplateVisitor.prototype.visitReference = function (ast, context) { }; - NullTemplateVisitor.prototype.visitVariable = function (ast, context) { }; - NullTemplateVisitor.prototype.visitEvent = function (ast, context) { }; - NullTemplateVisitor.prototype.visitElementProperty = function (ast, context) { }; - NullTemplateVisitor.prototype.visitAttr = function (ast, context) { }; - NullTemplateVisitor.prototype.visitBoundText = function (ast, context) { }; - NullTemplateVisitor.prototype.visitText = function (ast, context) { }; - NullTemplateVisitor.prototype.visitDirective = function (ast, context) { }; - NullTemplateVisitor.prototype.visitDirectiveProperty = function (ast, context) { }; - return NullTemplateVisitor; -}()); -/** - * Base class that can be used to build a visitor that visits each node - * in an template ast recursively. - */ -var RecursiveTemplateAstVisitor = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(RecursiveTemplateAstVisitor, _super); - function RecursiveTemplateAstVisitor() { - return _super.call(this) || this; - } - // Nodes with children - RecursiveTemplateAstVisitor.prototype.visitEmbeddedTemplate = function (ast, context) { - return this.visitChildren(context, function (visit) { - visit(ast.attrs); - visit(ast.references); - visit(ast.variables); - visit(ast.directives); - visit(ast.providers); - visit(ast.children); - }); - }; - RecursiveTemplateAstVisitor.prototype.visitElement = function (ast, context) { - return this.visitChildren(context, function (visit) { - visit(ast.attrs); - visit(ast.inputs); - visit(ast.outputs); - visit(ast.references); - visit(ast.directives); - visit(ast.providers); - visit(ast.children); - }); - }; - RecursiveTemplateAstVisitor.prototype.visitDirective = function (ast, context) { - return this.visitChildren(context, function (visit) { - visit(ast.inputs); - visit(ast.hostProperties); - visit(ast.hostEvents); - }); - }; - RecursiveTemplateAstVisitor.prototype.visitChildren = function (context, cb) { - var results = []; - var t = this; - function visit(children) { - if (children && children.length) - results.push(templateVisitAll(t, children, context)); - } - cb(visit); - return Array.prototype.concat.apply([], results); - }; - return RecursiveTemplateAstVisitor; -}(NullTemplateVisitor)); -/** - * Visit every node in a list of {@link TemplateAst}s with the given {@link TemplateAstVisitor}. - */ -function templateVisitAll(visitor, asts, context) { - if (context === void 0) { context = null; } - var result = []; - var visit = visitor.visit ? - function (ast) { return visitor.visit(ast, context) || ast.visit(visitor, context); } : - function (ast) { return ast.visit(visitor, context); }; - asts.forEach(function (ast) { - var astResult = visit(ast); - if (astResult) { - result.push(astResult); - } - }); - return result; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var ProviderError = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(ProviderError, _super); - function ProviderError(message, span) { - return _super.call(this, span, message) || this; - } - return ProviderError; -}(ParseError)); -var ProviderViewContext = /** @class */ (function () { - function ProviderViewContext(reflector, component) { - var _this = this; - this.reflector = reflector; - this.component = component; - this.errors = []; - this.viewQueries = _getViewQueries(component); - this.viewProviders = new Map(); - component.viewProviders.forEach(function (provider) { - if (_this.viewProviders.get(tokenReference(provider.token)) == null) { - _this.viewProviders.set(tokenReference(provider.token), true); - } - }); - } - return ProviderViewContext; -}()); -var ProviderElementContext = /** @class */ (function () { - function ProviderElementContext(viewContext, _parent, _isViewRoot, _directiveAsts, attrs, refs, isTemplate, contentQueryStartId, _sourceSpan) { - var _this = this; - this.viewContext = viewContext; - this._parent = _parent; - this._isViewRoot = _isViewRoot; - this._directiveAsts = _directiveAsts; - this._sourceSpan = _sourceSpan; - this._transformedProviders = new Map(); - this._seenProviders = new Map(); - this._queriedTokens = new Map(); - this.transformedHasViewContainer = false; - this._attrs = {}; - attrs.forEach(function (attrAst) { return _this._attrs[attrAst.name] = attrAst.value; }); - var directivesMeta = _directiveAsts.map(function (directiveAst) { return directiveAst.directive; }); - this._allProviders = - _resolveProvidersFromDirectives(directivesMeta, _sourceSpan, viewContext.errors); - this._contentQueries = _getContentQueries(contentQueryStartId, directivesMeta); - Array.from(this._allProviders.values()).forEach(function (provider) { - _this._addQueryReadsTo(provider.token, provider.token, _this._queriedTokens); - }); - if (isTemplate) { - var templateRefId = createTokenForExternalReference(this.viewContext.reflector, Identifiers.TemplateRef); - this._addQueryReadsTo(templateRefId, templateRefId, this._queriedTokens); - } - refs.forEach(function (refAst) { - var defaultQueryValue = refAst.value || - createTokenForExternalReference(_this.viewContext.reflector, Identifiers.ElementRef); - _this._addQueryReadsTo({ value: refAst.name }, defaultQueryValue, _this._queriedTokens); - }); - if (this._queriedTokens.get(this.viewContext.reflector.resolveExternalReference(Identifiers.ViewContainerRef))) { - this.transformedHasViewContainer = true; - } - // create the providers that we know are eager first - Array.from(this._allProviders.values()).forEach(function (provider) { - var eager = provider.eager || _this._queriedTokens.get(tokenReference(provider.token)); - if (eager) { - _this._getOrCreateLocalProvider(provider.providerType, provider.token, true); - } - }); - } - ProviderElementContext.prototype.afterElement = function () { - var _this = this; - // collect lazy providers - Array.from(this._allProviders.values()).forEach(function (provider) { - _this._getOrCreateLocalProvider(provider.providerType, provider.token, false); - }); - }; - Object.defineProperty(ProviderElementContext.prototype, "transformProviders", { - get: function () { - // Note: Maps keep their insertion order. - var lazyProviders = []; - var eagerProviders = []; - this._transformedProviders.forEach(function (provider) { - if (provider.eager) { - eagerProviders.push(provider); - } - else { - lazyProviders.push(provider); - } - }); - return lazyProviders.concat(eagerProviders); - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(ProviderElementContext.prototype, "transformedDirectiveAsts", { - get: function () { - var sortedProviderTypes = this.transformProviders.map(function (provider) { return provider.token.identifier; }); - var sortedDirectives = this._directiveAsts.slice(); - sortedDirectives.sort(function (dir1, dir2) { return sortedProviderTypes.indexOf(dir1.directive.type) - - sortedProviderTypes.indexOf(dir2.directive.type); }); - return sortedDirectives; - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(ProviderElementContext.prototype, "queryMatches", { - get: function () { - var allMatches = []; - this._queriedTokens.forEach(function (matches) { allMatches.push.apply(allMatches, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(matches)); }); - return allMatches; - }, - enumerable: true, - configurable: true - }); - ProviderElementContext.prototype._addQueryReadsTo = function (token, defaultValue, queryReadTokens) { - this._getQueriesFor(token).forEach(function (query) { - var queryValue = query.meta.read || defaultValue; - var tokenRef = tokenReference(queryValue); - var queryMatches = queryReadTokens.get(tokenRef); - if (!queryMatches) { - queryMatches = []; - queryReadTokens.set(tokenRef, queryMatches); - } - queryMatches.push({ queryId: query.queryId, value: queryValue }); - }); - }; - ProviderElementContext.prototype._getQueriesFor = function (token) { - var result = []; - var currentEl = this; - var distance = 0; - var queries; - while (currentEl !== null) { - queries = currentEl._contentQueries.get(tokenReference(token)); - if (queries) { - result.push.apply(result, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(queries.filter(function (query) { return query.meta.descendants || distance <= 1; }))); - } - if (currentEl._directiveAsts.length > 0) { - distance++; - } - currentEl = currentEl._parent; - } - queries = this.viewContext.viewQueries.get(tokenReference(token)); - if (queries) { - result.push.apply(result, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(queries)); - } - return result; - }; - ProviderElementContext.prototype._getOrCreateLocalProvider = function (requestingProviderType, token, eager) { - var _this = this; - var resolvedProvider = this._allProviders.get(tokenReference(token)); - if (!resolvedProvider || ((requestingProviderType === ProviderAstType.Directive || - requestingProviderType === ProviderAstType.PublicService) && - resolvedProvider.providerType === ProviderAstType.PrivateService) || - ((requestingProviderType === ProviderAstType.PrivateService || - requestingProviderType === ProviderAstType.PublicService) && - resolvedProvider.providerType === ProviderAstType.Builtin)) { - return null; - } - var transformedProviderAst = this._transformedProviders.get(tokenReference(token)); - if (transformedProviderAst) { - return transformedProviderAst; - } - if (this._seenProviders.get(tokenReference(token)) != null) { - this.viewContext.errors.push(new ProviderError("Cannot instantiate cyclic dependency! " + tokenName(token), this._sourceSpan)); - return null; - } - this._seenProviders.set(tokenReference(token), true); - var transformedProviders = resolvedProvider.providers.map(function (provider) { - var transformedUseValue = provider.useValue; - var transformedUseExisting = provider.useExisting; - var transformedDeps = undefined; - if (provider.useExisting != null) { - var existingDiDep = _this._getDependency(resolvedProvider.providerType, { token: provider.useExisting }, eager); - if (existingDiDep.token != null) { - transformedUseExisting = existingDiDep.token; - } - else { - transformedUseExisting = null; - transformedUseValue = existingDiDep.value; - } - } - else if (provider.useFactory) { - var deps = provider.deps || provider.useFactory.diDeps; - transformedDeps = - deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep, eager); }); - } - else if (provider.useClass) { - var deps = provider.deps || provider.useClass.diDeps; - transformedDeps = - deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep, eager); }); - } - return _transformProvider(provider, { - useExisting: transformedUseExisting, - useValue: transformedUseValue, - deps: transformedDeps - }); - }); - transformedProviderAst = - _transformProviderAst(resolvedProvider, { eager: eager, providers: transformedProviders }); - this._transformedProviders.set(tokenReference(token), transformedProviderAst); - return transformedProviderAst; - }; - ProviderElementContext.prototype._getLocalDependency = function (requestingProviderType, dep, eager) { - if (eager === void 0) { eager = false; } - if (dep.isAttribute) { - var attrValue = this._attrs[dep.token.value]; - return { isValue: true, value: attrValue == null ? null : attrValue }; - } - if (dep.token != null) { - // access builtints - if ((requestingProviderType === ProviderAstType.Directive || - requestingProviderType === ProviderAstType.Component)) { - if (tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.Renderer) || - tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.ElementRef) || - tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.ChangeDetectorRef) || - tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.TemplateRef)) { - return dep; - } - if (tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.ViewContainerRef)) { - this.transformedHasViewContainer = true; - } - } - // access the injector - if (tokenReference(dep.token) === - this.viewContext.reflector.resolveExternalReference(Identifiers.Injector)) { - return dep; - } - // access providers - if (this._getOrCreateLocalProvider(requestingProviderType, dep.token, eager) != null) { - return dep; - } - } - return null; - }; - ProviderElementContext.prototype._getDependency = function (requestingProviderType, dep, eager) { - if (eager === void 0) { eager = false; } - var currElement = this; - var currEager = eager; - var result = null; - if (!dep.isSkipSelf) { - result = this._getLocalDependency(requestingProviderType, dep, eager); - } - if (dep.isSelf) { - if (!result && dep.isOptional) { - result = { isValue: true, value: null }; - } - } - else { - // check parent elements - while (!result && currElement._parent) { - var prevElement = currElement; - currElement = currElement._parent; - if (prevElement._isViewRoot) { - currEager = false; - } - result = currElement._getLocalDependency(ProviderAstType.PublicService, dep, currEager); - } - // check @Host restriction - if (!result) { - if (!dep.isHost || this.viewContext.component.isHost || - this.viewContext.component.type.reference === tokenReference(dep.token) || - this.viewContext.viewProviders.get(tokenReference(dep.token)) != null) { - result = dep; - } - else { - result = dep.isOptional ? { isValue: true, value: null } : null; - } - } - } - if (!result) { - this.viewContext.errors.push(new ProviderError("No provider for " + tokenName(dep.token), this._sourceSpan)); - } - return result; - }; - return ProviderElementContext; -}()); -var NgModuleProviderAnalyzer = /** @class */ (function () { - function NgModuleProviderAnalyzer(reflector, ngModule, extraProviders, sourceSpan) { - var _this = this; - this.reflector = reflector; - this._transformedProviders = new Map(); - this._seenProviders = new Map(); - this._errors = []; - this._allProviders = new Map(); - ngModule.transitiveModule.modules.forEach(function (ngModuleType) { - var ngModuleProvider = { token: { identifier: ngModuleType }, useClass: ngModuleType }; - _resolveProviders([ngModuleProvider], ProviderAstType.PublicService, true, sourceSpan, _this._errors, _this._allProviders, /* isModule */ true); - }); - _resolveProviders(ngModule.transitiveModule.providers.map(function (entry) { return entry.provider; }).concat(extraProviders), ProviderAstType.PublicService, false, sourceSpan, this._errors, this._allProviders, - /* isModule */ false); - } - NgModuleProviderAnalyzer.prototype.parse = function () { - var _this = this; - Array.from(this._allProviders.values()).forEach(function (provider) { - _this._getOrCreateLocalProvider(provider.token, provider.eager); - }); - if (this._errors.length > 0) { - var errorString = this._errors.join('\n'); - throw new Error("Provider parse errors:\n" + errorString); - } - // Note: Maps keep their insertion order. - var lazyProviders = []; - var eagerProviders = []; - this._transformedProviders.forEach(function (provider) { - if (provider.eager) { - eagerProviders.push(provider); - } - else { - lazyProviders.push(provider); - } - }); - return lazyProviders.concat(eagerProviders); - }; - NgModuleProviderAnalyzer.prototype._getOrCreateLocalProvider = function (token, eager) { - var _this = this; - var resolvedProvider = this._allProviders.get(tokenReference(token)); - if (!resolvedProvider) { - return null; - } - var transformedProviderAst = this._transformedProviders.get(tokenReference(token)); - if (transformedProviderAst) { - return transformedProviderAst; - } - if (this._seenProviders.get(tokenReference(token)) != null) { - this._errors.push(new ProviderError("Cannot instantiate cyclic dependency! " + tokenName(token), resolvedProvider.sourceSpan)); - return null; - } - this._seenProviders.set(tokenReference(token), true); - var transformedProviders = resolvedProvider.providers.map(function (provider) { - var transformedUseValue = provider.useValue; - var transformedUseExisting = provider.useExisting; - var transformedDeps = undefined; - if (provider.useExisting != null) { - var existingDiDep = _this._getDependency({ token: provider.useExisting }, eager, resolvedProvider.sourceSpan); - if (existingDiDep.token != null) { - transformedUseExisting = existingDiDep.token; - } - else { - transformedUseExisting = null; - transformedUseValue = existingDiDep.value; - } - } - else if (provider.useFactory) { - var deps = provider.deps || provider.useFactory.diDeps; - transformedDeps = - deps.map(function (dep) { return _this._getDependency(dep, eager, resolvedProvider.sourceSpan); }); - } - else if (provider.useClass) { - var deps = provider.deps || provider.useClass.diDeps; - transformedDeps = - deps.map(function (dep) { return _this._getDependency(dep, eager, resolvedProvider.sourceSpan); }); - } - return _transformProvider(provider, { - useExisting: transformedUseExisting, - useValue: transformedUseValue, - deps: transformedDeps - }); - }); - transformedProviderAst = - _transformProviderAst(resolvedProvider, { eager: eager, providers: transformedProviders }); - this._transformedProviders.set(tokenReference(token), transformedProviderAst); - return transformedProviderAst; - }; - NgModuleProviderAnalyzer.prototype._getDependency = function (dep, eager, requestorSourceSpan) { - if (eager === void 0) { eager = false; } - var foundLocal = false; - if (!dep.isSkipSelf && dep.token != null) { - // access the injector - if (tokenReference(dep.token) === - this.reflector.resolveExternalReference(Identifiers.Injector) || - tokenReference(dep.token) === - this.reflector.resolveExternalReference(Identifiers.ComponentFactoryResolver)) { - foundLocal = true; - // access providers - } - else if (this._getOrCreateLocalProvider(dep.token, eager) != null) { - foundLocal = true; - } - } - return dep; - }; - return NgModuleProviderAnalyzer; -}()); -function _transformProvider(provider, _a) { - var useExisting = _a.useExisting, useValue = _a.useValue, deps = _a.deps; - return { - token: provider.token, - useClass: provider.useClass, - useExisting: useExisting, - useFactory: provider.useFactory, - useValue: useValue, - deps: deps, - multi: provider.multi - }; -} -function _transformProviderAst(provider, _a) { - var eager = _a.eager, providers = _a.providers; - return new ProviderAst(provider.token, provider.multiProvider, provider.eager || eager, providers, provider.providerType, provider.lifecycleHooks, provider.sourceSpan, provider.isModule); -} -function _resolveProvidersFromDirectives(directives, sourceSpan, targetErrors) { - var providersByToken = new Map(); - directives.forEach(function (directive) { - var dirProvider = { token: { identifier: directive.type }, useClass: directive.type }; - _resolveProviders([dirProvider], directive.isComponent ? ProviderAstType.Component : ProviderAstType.Directive, true, sourceSpan, targetErrors, providersByToken, /* isModule */ false); - }); - // Note: directives need to be able to overwrite providers of a component! - var directivesWithComponentFirst = directives.filter(function (dir) { return dir.isComponent; }).concat(directives.filter(function (dir) { return !dir.isComponent; })); - directivesWithComponentFirst.forEach(function (directive) { - _resolveProviders(directive.providers, ProviderAstType.PublicService, false, sourceSpan, targetErrors, providersByToken, /* isModule */ false); - _resolveProviders(directive.viewProviders, ProviderAstType.PrivateService, false, sourceSpan, targetErrors, providersByToken, /* isModule */ false); - }); - return providersByToken; -} -function _resolveProviders(providers, providerType, eager, sourceSpan, targetErrors, targetProvidersByToken, isModule) { - providers.forEach(function (provider) { - var resolvedProvider = targetProvidersByToken.get(tokenReference(provider.token)); - if (resolvedProvider != null && !!resolvedProvider.multiProvider !== !!provider.multi) { - targetErrors.push(new ProviderError("Mixing multi and non multi provider is not possible for token " + tokenName(resolvedProvider.token), sourceSpan)); - } - if (!resolvedProvider) { - var lifecycleHooks = provider.token.identifier && - provider.token.identifier.lifecycleHooks ? - provider.token.identifier.lifecycleHooks : - []; - var isUseValue = !(provider.useClass || provider.useExisting || provider.useFactory); - resolvedProvider = new ProviderAst(provider.token, !!provider.multi, eager || isUseValue, [provider], providerType, lifecycleHooks, sourceSpan, isModule); - targetProvidersByToken.set(tokenReference(provider.token), resolvedProvider); - } - else { - if (!provider.multi) { - resolvedProvider.providers.length = 0; - } - resolvedProvider.providers.push(provider); - } - }); -} -function _getViewQueries(component) { - // Note: queries start with id 1 so we can use the number in a Bloom filter! - var viewQueryId = 1; - var viewQueries = new Map(); - if (component.viewQueries) { - component.viewQueries.forEach(function (query) { return _addQueryToTokenMap(viewQueries, { meta: query, queryId: viewQueryId++ }); }); - } - return viewQueries; -} -function _getContentQueries(contentQueryStartId, directives) { - var contentQueryId = contentQueryStartId; - var contentQueries = new Map(); - directives.forEach(function (directive, directiveIndex) { - if (directive.queries) { - directive.queries.forEach(function (query) { return _addQueryToTokenMap(contentQueries, { meta: query, queryId: contentQueryId++ }); }); - } - }); - return contentQueries; -} -function _addQueryToTokenMap(map, query) { - query.meta.selectors.forEach(function (token) { - var entry = map.get(tokenReference(token)); - if (!entry) { - entry = []; - map.set(tokenReference(token), entry); - } - entry.push(query); - }); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var StyleWithImports = /** @class */ (function () { - function StyleWithImports(style, styleUrls) { - this.style = style; - this.styleUrls = styleUrls; - } - return StyleWithImports; -}()); -function isStyleUrlResolvable(url) { - if (url == null || url.length === 0 || url[0] == '/') - return false; - var schemeMatch = url.match(URL_WITH_SCHEMA_REGEXP); - return schemeMatch === null || schemeMatch[1] == 'package' || schemeMatch[1] == 'asset'; -} -/** - * Rewrites stylesheets by resolving and removing the @import urls that - * are either relative or don't have a `package:` scheme - */ -function extractStyleUrls(resolver, baseUrl, cssText) { - var foundUrls = []; - var modifiedCssText = cssText.replace(CSS_STRIPPABLE_COMMENT_REGEXP, '') - .replace(CSS_IMPORT_REGEXP, function () { - var m = []; - for (var _i = 0; _i < arguments.length; _i++) { - m[_i] = arguments[_i]; - } - var url = m[1] || m[2]; - if (!isStyleUrlResolvable(url)) { - // Do not attempt to resolve non-package absolute URLs with URI - // scheme - return m[0]; - } - foundUrls.push(resolver.resolve(baseUrl, url)); - return ''; - }); - return new StyleWithImports(modifiedCssText, foundUrls); -} -var CSS_IMPORT_REGEXP = /@import\s+(?:url\()?\s*(?:(?:['"]([^'"]*))|([^;\)\s]*))[^;]*;?/g; -var CSS_STRIPPABLE_COMMENT_REGEXP = /\/\*(?!#\s*(?:sourceURL|sourceMappingURL)=)[\s\S]+?\*\//g; -var URL_WITH_SCHEMA_REGEXP = /^([^:/?#]+):/; - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var PROPERTY_PARTS_SEPARATOR = '.'; -var ATTRIBUTE_PREFIX = 'attr'; -var CLASS_PREFIX = 'class'; -var STYLE_PREFIX = 'style'; -var ANIMATE_PROP_PREFIX = 'animate-'; -/** - * Parses bindings in templates and in the directive host area. - */ -var BindingParser = /** @class */ (function () { - function BindingParser(_exprParser, _interpolationConfig, _schemaRegistry, pipes, errors) { - this._exprParser = _exprParser; - this._interpolationConfig = _interpolationConfig; - this._schemaRegistry = _schemaRegistry; - this.errors = errors; - this.pipesByName = null; - this._usedPipes = new Map(); - // When the `pipes` parameter is `null`, do not check for used pipes - // This is used in IVY when we might not know the available pipes at compile time - if (pipes) { - var pipesByName_1 = new Map(); - pipes.forEach(function (pipe) { return pipesByName_1.set(pipe.name, pipe); }); - this.pipesByName = pipesByName_1; - } - } - Object.defineProperty(BindingParser.prototype, "interpolationConfig", { - get: function () { return this._interpolationConfig; }, - enumerable: true, - configurable: true - }); - BindingParser.prototype.getUsedPipes = function () { return Array.from(this._usedPipes.values()); }; - BindingParser.prototype.createBoundHostProperties = function (dirMeta, sourceSpan) { - var _this = this; - if (dirMeta.hostProperties) { - var boundProps_1 = []; - Object.keys(dirMeta.hostProperties).forEach(function (propName) { - var expression = dirMeta.hostProperties[propName]; - if (typeof expression === 'string') { - _this.parsePropertyBinding(propName, expression, true, sourceSpan, sourceSpan.start.offset, undefined, [], boundProps_1); - } - else { - _this._reportError("Value of the host property binding \"" + propName + "\" needs to be a string representing an expression but got \"" + expression + "\" (" + typeof expression + ")", sourceSpan); - } - }); - return boundProps_1; - } - return null; - }; - BindingParser.prototype.createDirectiveHostPropertyAsts = function (dirMeta, elementSelector, sourceSpan) { - var _this = this; - var boundProps = this.createBoundHostProperties(dirMeta, sourceSpan); - return boundProps && - boundProps.map(function (prop) { return _this.createBoundElementProperty(elementSelector, prop); }); - }; - BindingParser.prototype.createDirectiveHostEventAsts = function (dirMeta, sourceSpan) { - var _this = this; - if (dirMeta.hostListeners) { - var targetEvents_1 = []; - Object.keys(dirMeta.hostListeners).forEach(function (propName) { - var expression = dirMeta.hostListeners[propName]; - if (typeof expression === 'string') { - // TODO: pass a more accurate handlerSpan for this event. - _this.parseEvent(propName, expression, sourceSpan, sourceSpan, [], targetEvents_1); - } - else { - _this._reportError("Value of the host listener \"" + propName + "\" needs to be a string representing an expression but got \"" + expression + "\" (" + typeof expression + ")", sourceSpan); - } - }); - return targetEvents_1; - } - return null; - }; - BindingParser.prototype.parseInterpolation = function (value, sourceSpan) { - var sourceInfo = sourceSpan.start.toString(); - try { - var ast = this._exprParser.parseInterpolation(value, sourceInfo, sourceSpan.start.offset, this._interpolationConfig); - if (ast) - this._reportExpressionParserErrors(ast.errors, sourceSpan); - this._checkPipes(ast, sourceSpan); - return ast; - } - catch (e) { - this._reportError("" + e, sourceSpan); - return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo, sourceSpan.start.offset); - } - }; - // Parse an inline template binding. ie `` - BindingParser.prototype.parseInlineTemplateBinding = function (tplKey, tplValue, sourceSpan, absoluteOffset, targetMatchableAttrs, targetProps, targetVars) { - var bindings = this._parseTemplateBindings(tplKey, tplValue, sourceSpan); - for (var i = 0; i < bindings.length; i++) { - var binding = bindings[i]; - if (binding.keyIsVar) { - targetVars.push(new ParsedVariable(binding.key, binding.name, sourceSpan)); - } - else if (binding.expression) { - this._parsePropertyAst(binding.key, binding.expression, sourceSpan, undefined, targetMatchableAttrs, targetProps); - } - else { - targetMatchableAttrs.push([binding.key, '']); - this.parseLiteralAttr(binding.key, null, sourceSpan, absoluteOffset, undefined, targetMatchableAttrs, targetProps); - } - } - }; - BindingParser.prototype._parseTemplateBindings = function (tplKey, tplValue, sourceSpan) { - var _this = this; - var sourceInfo = sourceSpan.start.toString(); - try { - var bindingsResult = this._exprParser.parseTemplateBindings(tplKey, tplValue, sourceInfo, sourceSpan.start.offset); - this._reportExpressionParserErrors(bindingsResult.errors, sourceSpan); - bindingsResult.templateBindings.forEach(function (binding) { - if (binding.expression) { - _this._checkPipes(binding.expression, sourceSpan); - } - }); - bindingsResult.warnings.forEach(function (warning) { _this._reportError(warning, sourceSpan, ParseErrorLevel.WARNING); }); - return bindingsResult.templateBindings; - } - catch (e) { - this._reportError("" + e, sourceSpan); - return []; - } - }; - BindingParser.prototype.parseLiteralAttr = function (name, value, sourceSpan, absoluteOffset, valueSpan, targetMatchableAttrs, targetProps) { - if (isAnimationLabel(name)) { - name = name.substring(1); - if (value) { - this._reportError("Assigning animation triggers via @prop=\"exp\" attributes with an expression is invalid." + - " Use property bindings (e.g. [@prop]=\"exp\") or use an attribute without a value (e.g. @prop) instead.", sourceSpan, ParseErrorLevel.ERROR); - } - this._parseAnimation(name, value, sourceSpan, absoluteOffset, valueSpan, targetMatchableAttrs, targetProps); - } - else { - targetProps.push(new ParsedProperty(name, this._exprParser.wrapLiteralPrimitive(value, '', absoluteOffset), ParsedPropertyType.LITERAL_ATTR, sourceSpan, valueSpan)); - } - }; - BindingParser.prototype.parsePropertyBinding = function (name, expression, isHost, sourceSpan, absoluteOffset, valueSpan, targetMatchableAttrs, targetProps) { - var isAnimationProp = false; - if (name.startsWith(ANIMATE_PROP_PREFIX)) { - isAnimationProp = true; - name = name.substring(ANIMATE_PROP_PREFIX.length); - } - else if (isAnimationLabel(name)) { - isAnimationProp = true; - name = name.substring(1); - } - if (isAnimationProp) { - this._parseAnimation(name, expression, sourceSpan, absoluteOffset, valueSpan, targetMatchableAttrs, targetProps); - } - else { - this._parsePropertyAst(name, this._parseBinding(expression, isHost, valueSpan || sourceSpan, absoluteOffset), sourceSpan, valueSpan, targetMatchableAttrs, targetProps); - } - }; - BindingParser.prototype.parsePropertyInterpolation = function (name, value, sourceSpan, valueSpan, targetMatchableAttrs, targetProps) { - var expr = this.parseInterpolation(value, valueSpan || sourceSpan); - if (expr) { - this._parsePropertyAst(name, expr, sourceSpan, valueSpan, targetMatchableAttrs, targetProps); - return true; - } - return false; - }; - BindingParser.prototype._parsePropertyAst = function (name, ast, sourceSpan, valueSpan, targetMatchableAttrs, targetProps) { - targetMatchableAttrs.push([name, ast.source]); - targetProps.push(new ParsedProperty(name, ast, ParsedPropertyType.DEFAULT, sourceSpan, valueSpan)); - }; - BindingParser.prototype._parseAnimation = function (name, expression, sourceSpan, absoluteOffset, valueSpan, targetMatchableAttrs, targetProps) { - // This will occur when a @trigger is not paired with an expression. - // For animations it is valid to not have an expression since */void - // states will be applied by angular when the element is attached/detached - var ast = this._parseBinding(expression || 'undefined', false, valueSpan || sourceSpan, absoluteOffset); - targetMatchableAttrs.push([name, ast.source]); - targetProps.push(new ParsedProperty(name, ast, ParsedPropertyType.ANIMATION, sourceSpan, valueSpan)); - }; - BindingParser.prototype._parseBinding = function (value, isHostBinding, sourceSpan, absoluteOffset) { - var sourceInfo = (sourceSpan && sourceSpan.start || '(unknown)').toString(); - try { - var ast = isHostBinding ? - this._exprParser.parseSimpleBinding(value, sourceInfo, absoluteOffset, this._interpolationConfig) : - this._exprParser.parseBinding(value, sourceInfo, absoluteOffset, this._interpolationConfig); - if (ast) - this._reportExpressionParserErrors(ast.errors, sourceSpan); - this._checkPipes(ast, sourceSpan); - return ast; - } - catch (e) { - this._reportError("" + e, sourceSpan); - return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo, absoluteOffset); - } - }; - BindingParser.prototype.createBoundElementProperty = function (elementSelector, boundProp, skipValidation, mapPropertyName) { - if (skipValidation === void 0) { skipValidation = false; } - if (mapPropertyName === void 0) { mapPropertyName = true; } - if (boundProp.isAnimation) { - return new BoundElementProperty(boundProp.name, 4 /* Animation */, SecurityContext.NONE, boundProp.expression, null, boundProp.sourceSpan, boundProp.valueSpan); - } - var unit = null; - var bindingType = undefined; - var boundPropertyName = null; - var parts = boundProp.name.split(PROPERTY_PARTS_SEPARATOR); - var securityContexts = undefined; - // Check for special cases (prefix style, attr, class) - if (parts.length > 1) { - if (parts[0] == ATTRIBUTE_PREFIX) { - boundPropertyName = parts[1]; - if (!skipValidation) { - this._validatePropertyOrAttributeName(boundPropertyName, boundProp.sourceSpan, true); - } - securityContexts = calcPossibleSecurityContexts(this._schemaRegistry, elementSelector, boundPropertyName, true); - var nsSeparatorIdx = boundPropertyName.indexOf(':'); - if (nsSeparatorIdx > -1) { - var ns = boundPropertyName.substring(0, nsSeparatorIdx); - var name_1 = boundPropertyName.substring(nsSeparatorIdx + 1); - boundPropertyName = mergeNsAndName(ns, name_1); - } - bindingType = 1 /* Attribute */; - } - else if (parts[0] == CLASS_PREFIX) { - boundPropertyName = parts[1]; - bindingType = 2 /* Class */; - securityContexts = [SecurityContext.NONE]; - } - else if (parts[0] == STYLE_PREFIX) { - unit = parts.length > 2 ? parts[2] : null; - boundPropertyName = parts[1]; - bindingType = 3 /* Style */; - securityContexts = [SecurityContext.STYLE]; - } - } - // If not a special case, use the full property name - if (boundPropertyName === null) { - var mappedPropName = this._schemaRegistry.getMappedPropName(boundProp.name); - boundPropertyName = mapPropertyName ? mappedPropName : boundProp.name; - securityContexts = calcPossibleSecurityContexts(this._schemaRegistry, elementSelector, mappedPropName, false); - bindingType = 0 /* Property */; - if (!skipValidation) { - this._validatePropertyOrAttributeName(mappedPropName, boundProp.sourceSpan, false); - } - } - return new BoundElementProperty(boundPropertyName, bindingType, securityContexts[0], boundProp.expression, unit, boundProp.sourceSpan, boundProp.valueSpan); - }; - BindingParser.prototype.parseEvent = function (name, expression, sourceSpan, handlerSpan, targetMatchableAttrs, targetEvents) { - if (isAnimationLabel(name)) { - name = name.substr(1); - this._parseAnimationEvent(name, expression, sourceSpan, handlerSpan, targetEvents); - } - else { - this._parseRegularEvent(name, expression, sourceSpan, handlerSpan, targetMatchableAttrs, targetEvents); - } - }; - BindingParser.prototype.calcPossibleSecurityContexts = function (selector, propName, isAttribute) { - var prop = this._schemaRegistry.getMappedPropName(propName); - return calcPossibleSecurityContexts(this._schemaRegistry, selector, prop, isAttribute); - }; - BindingParser.prototype._parseAnimationEvent = function (name, expression, sourceSpan, handlerSpan, targetEvents) { - var matches = splitAtPeriod(name, [name, '']); - var eventName = matches[0]; - var phase = matches[1].toLowerCase(); - if (phase) { - switch (phase) { - case 'start': - case 'done': - var ast = this._parseAction(expression, handlerSpan); - targetEvents.push(new ParsedEvent(eventName, phase, 1 /* Animation */, ast, sourceSpan, handlerSpan)); - break; - default: - this._reportError("The provided animation output phase value \"" + phase + "\" for \"@" + eventName + "\" is not supported (use start or done)", sourceSpan); - break; - } - } - else { - this._reportError("The animation trigger output event (@" + eventName + ") is missing its phase value name (start or done are currently supported)", sourceSpan); - } - }; - BindingParser.prototype._parseRegularEvent = function (name, expression, sourceSpan, handlerSpan, targetMatchableAttrs, targetEvents) { - // long format: 'target: eventName' - var _a = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__read"])(splitAtColon(name, [null, name]), 2), target = _a[0], eventName = _a[1]; - var ast = this._parseAction(expression, handlerSpan); - targetMatchableAttrs.push([name, ast.source]); - targetEvents.push(new ParsedEvent(eventName, target, 0 /* Regular */, ast, sourceSpan, handlerSpan)); - // Don't detect directives for event names for now, - // so don't add the event name to the matchableAttrs - }; - BindingParser.prototype._parseAction = function (value, sourceSpan) { - var sourceInfo = (sourceSpan && sourceSpan.start || '(unknown').toString(); - var absoluteOffset = (sourceSpan && sourceSpan.start) ? sourceSpan.start.offset : 0; - try { - var ast = this._exprParser.parseAction(value, sourceInfo, absoluteOffset, this._interpolationConfig); - if (ast) { - this._reportExpressionParserErrors(ast.errors, sourceSpan); - } - if (!ast || ast.ast instanceof EmptyExpr) { - this._reportError("Empty expressions are not allowed", sourceSpan); - return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo, absoluteOffset); - } - this._checkPipes(ast, sourceSpan); - return ast; - } - catch (e) { - this._reportError("" + e, sourceSpan); - return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo, absoluteOffset); - } - }; - BindingParser.prototype._reportError = function (message, sourceSpan, level) { - if (level === void 0) { level = ParseErrorLevel.ERROR; } - this.errors.push(new ParseError(sourceSpan, message, level)); - }; - BindingParser.prototype._reportExpressionParserErrors = function (errors, sourceSpan) { - var e_1, _a; - try { - for (var errors_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__values"])(errors), errors_1_1 = errors_1.next(); !errors_1_1.done; errors_1_1 = errors_1.next()) { - var error = errors_1_1.value; - this._reportError(error.message, sourceSpan); - } - } - catch (e_1_1) { e_1 = { error: e_1_1 }; } - finally { - try { - if (errors_1_1 && !errors_1_1.done && (_a = errors_1.return)) _a.call(errors_1); - } - finally { if (e_1) throw e_1.error; } - } - }; - // Make sure all the used pipes are known in `this.pipesByName` - BindingParser.prototype._checkPipes = function (ast, sourceSpan) { - var _this = this; - if (ast && this.pipesByName) { - var collector = new PipeCollector(); - ast.visit(collector); - collector.pipes.forEach(function (ast, pipeName) { - var pipeMeta = _this.pipesByName.get(pipeName); - if (!pipeMeta) { - _this._reportError("The pipe '" + pipeName + "' could not be found", new ParseSourceSpan(sourceSpan.start.moveBy(ast.span.start), sourceSpan.start.moveBy(ast.span.end))); - } - else { - _this._usedPipes.set(pipeName, pipeMeta); - } - }); - } - }; - /** - * @param propName the name of the property / attribute - * @param sourceSpan - * @param isAttr true when binding to an attribute - */ - BindingParser.prototype._validatePropertyOrAttributeName = function (propName, sourceSpan, isAttr) { - var report = isAttr ? this._schemaRegistry.validateAttribute(propName) : - this._schemaRegistry.validateProperty(propName); - if (report.error) { - this._reportError(report.msg, sourceSpan, ParseErrorLevel.ERROR); - } - }; - return BindingParser; -}()); -var PipeCollector = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(PipeCollector, _super); - function PipeCollector() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this.pipes = new Map(); - return _this; - } - PipeCollector.prototype.visitPipe = function (ast, context) { - this.pipes.set(ast.name, ast); - ast.exp.visit(this); - this.visitAll(ast.args, context); - return null; - }; - return PipeCollector; -}(RecursiveAstVisitor$1)); -function isAnimationLabel(name) { - return name[0] == '@'; -} -function calcPossibleSecurityContexts(registry, selector, propName, isAttribute) { - var ctxs = []; - CssSelector.parse(selector).forEach(function (selector) { - var elementNames = selector.element ? [selector.element] : registry.allKnownElementNames(); - var notElementNames = new Set(selector.notSelectors.filter(function (selector) { return selector.isElementSelector(); }) - .map(function (selector) { return selector.element; })); - var possibleElementNames = elementNames.filter(function (elementName) { return !notElementNames.has(elementName); }); - ctxs.push.apply(ctxs, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(possibleElementNames.map(function (elementName) { return registry.securityContext(elementName, propName, isAttribute); }))); - }); - return ctxs.length === 0 ? [SecurityContext.NONE] : Array.from(new Set(ctxs)).sort(); -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var NG_CONTENT_SELECT_ATTR = 'select'; -var LINK_ELEMENT = 'link'; -var LINK_STYLE_REL_ATTR = 'rel'; -var LINK_STYLE_HREF_ATTR = 'href'; -var LINK_STYLE_REL_VALUE = 'stylesheet'; -var STYLE_ELEMENT = 'style'; -var SCRIPT_ELEMENT = 'script'; -var NG_NON_BINDABLE_ATTR = 'ngNonBindable'; -var NG_PROJECT_AS = 'ngProjectAs'; -function preparseElement(ast) { - var selectAttr = null; - var hrefAttr = null; - var relAttr = null; - var nonBindable = false; - var projectAs = ''; - ast.attrs.forEach(function (attr) { - var lcAttrName = attr.name.toLowerCase(); - if (lcAttrName == NG_CONTENT_SELECT_ATTR) { - selectAttr = attr.value; - } - else if (lcAttrName == LINK_STYLE_HREF_ATTR) { - hrefAttr = attr.value; - } - else if (lcAttrName == LINK_STYLE_REL_ATTR) { - relAttr = attr.value; - } - else if (attr.name == NG_NON_BINDABLE_ATTR) { - nonBindable = true; - } - else if (attr.name == NG_PROJECT_AS) { - if (attr.value.length > 0) { - projectAs = attr.value; - } - } - }); - selectAttr = normalizeNgContentSelect(selectAttr); - var nodeName = ast.name.toLowerCase(); - var type = PreparsedElementType.OTHER; - if (isNgContent(nodeName)) { - type = PreparsedElementType.NG_CONTENT; - } - else if (nodeName == STYLE_ELEMENT) { - type = PreparsedElementType.STYLE; - } - else if (nodeName == SCRIPT_ELEMENT) { - type = PreparsedElementType.SCRIPT; - } - else if (nodeName == LINK_ELEMENT && relAttr == LINK_STYLE_REL_VALUE) { - type = PreparsedElementType.STYLESHEET; - } - return new PreparsedElement(type, selectAttr, hrefAttr, nonBindable, projectAs); -} -var PreparsedElementType; -(function (PreparsedElementType) { - PreparsedElementType[PreparsedElementType["NG_CONTENT"] = 0] = "NG_CONTENT"; - PreparsedElementType[PreparsedElementType["STYLE"] = 1] = "STYLE"; - PreparsedElementType[PreparsedElementType["STYLESHEET"] = 2] = "STYLESHEET"; - PreparsedElementType[PreparsedElementType["SCRIPT"] = 3] = "SCRIPT"; - PreparsedElementType[PreparsedElementType["OTHER"] = 4] = "OTHER"; -})(PreparsedElementType || (PreparsedElementType = {})); -var PreparsedElement = /** @class */ (function () { - function PreparsedElement(type, selectAttr, hrefAttr, nonBindable, projectAs) { - this.type = type; - this.selectAttr = selectAttr; - this.hrefAttr = hrefAttr; - this.nonBindable = nonBindable; - this.projectAs = projectAs; - } - return PreparsedElement; -}()); -function normalizeNgContentSelect(selectAttr) { - if (selectAttr === null || selectAttr.length === 0) { - return '*'; - } - return selectAttr; -} - -/** - * @license - * Copyright Google Inc. All Rights Reserved. - * - * 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 - */ -var BIND_NAME_REGEXP = /^(?:(?:(?:(bind-)|(let-)|(ref-|#)|(on-)|(bindon-)|(@))(.+))|\[\(([^\)]+)\)\]|\[([^\]]+)\]|\(([^\)]+)\))$/; -// Group 1 = "bind-" -var KW_BIND_IDX = 1; -// Group 2 = "let-" -var KW_LET_IDX = 2; -// Group 3 = "ref-/#" -var KW_REF_IDX = 3; -// Group 4 = "on-" -var KW_ON_IDX = 4; -// Group 5 = "bindon-" -var KW_BINDON_IDX = 5; -// Group 6 = "@" -var KW_AT_IDX = 6; -// Group 7 = the identifier after "bind-", "let-", "ref-/#", "on-", "bindon-" or "@" -var IDENT_KW_IDX = 7; -// Group 8 = identifier inside [()] -var IDENT_BANANA_BOX_IDX = 8; -// Group 9 = identifier inside [] -var IDENT_PROPERTY_IDX = 9; -// Group 10 = identifier inside () -var IDENT_EVENT_IDX = 10; -var TEMPLATE_ATTR_PREFIX = '*'; -var CLASS_ATTR = 'class'; -var _TEXT_CSS_SELECTOR; -function TEXT_CSS_SELECTOR() { - if (!_TEXT_CSS_SELECTOR) { - _TEXT_CSS_SELECTOR = CssSelector.parse('*')[0]; - } - return _TEXT_CSS_SELECTOR; -} -var TemplateParseError = /** @class */ (function (_super) { - Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"])(TemplateParseError, _super); - function TemplateParseError(message, span, level) { - return _super.call(this, span, message, level) || this; - } - return TemplateParseError; -}(ParseError)); -var TemplateParseResult = /** @class */ (function () { - function TemplateParseResult(templateAst, usedPipes, errors) { - this.templateAst = templateAst; - this.usedPipes = usedPipes; - this.errors = errors; - } - return TemplateParseResult; -}()); -var TemplateParser = /** @class */ (function () { - function TemplateParser(_config, _reflector, _exprParser, _schemaRegistry, _htmlParser, _console, transforms) { - this._config = _config; - this._reflector = _reflector; - this._exprParser = _exprParser; - this._schemaRegistry = _schemaRegistry; - this._htmlParser = _htmlParser; - this._console = _console; - this.transforms = transforms; - } - Object.defineProperty(TemplateParser.prototype, "expressionParser", { - get: function () { return this._exprParser; }, - enumerable: true, - configurable: true - }); - TemplateParser.prototype.parse = function (component, template, directives, pipes, schemas, templateUrl, preserveWhitespaces) { - var result = this.tryParse(component, template, directives, pipes, schemas, templateUrl, preserveWhitespaces); - var warnings = result.errors.filter(function (error) { return error.level === ParseErrorLevel.WARNING; }); - var errors = result.errors.filter(function (error) { return error.level === ParseErrorLevel.ERROR; }); - if (warnings.length > 0) { - this._console.warn("Template parse warnings:\n" + warnings.join('\n')); - } - if (errors.length > 0) { - var errorString = errors.join('\n'); - throw syntaxError("Template parse errors:\n" + errorString, errors); - } - return { template: result.templateAst, pipes: result.usedPipes }; - }; - TemplateParser.prototype.tryParse = function (component, template, directives, pipes, schemas, templateUrl, preserveWhitespaces) { - var htmlParseResult = typeof template === 'string' ? - this._htmlParser.parse(template, templateUrl, { - tokenizeExpansionForms: true, - interpolationConfig: this.getInterpolationConfig(component) - }) : - template; - if (!preserveWhitespaces) { - htmlParseResult = removeWhitespaces(htmlParseResult); - } - return this.tryParseHtml(this.expandHtml(htmlParseResult), component, directives, pipes, schemas); - }; - TemplateParser.prototype.tryParseHtml = function (htmlAstWithErrors, component, directives, pipes, schemas) { - var result; - var errors = htmlAstWithErrors.errors; - var usedPipes = []; - if (htmlAstWithErrors.rootNodes.length > 0) { - var uniqDirectives = removeSummaryDuplicates(directives); - var uniqPipes = removeSummaryDuplicates(pipes); - var providerViewContext = new ProviderViewContext(this._reflector, component); - var interpolationConfig = undefined; - if (component.template && component.template.interpolation) { - interpolationConfig = { - start: component.template.interpolation[0], - end: component.template.interpolation[1] - }; - } - var bindingParser = new BindingParser(this._exprParser, interpolationConfig, this._schemaRegistry, uniqPipes, errors); - var parseVisitor = new TemplateParseVisitor(this._reflector, this._config, providerViewContext, uniqDirectives, bindingParser, this._schemaRegistry, schemas, errors); - result = visitAll$1(parseVisitor, htmlAstWithErrors.rootNodes, EMPTY_ELEMENT_CONTEXT); - errors.push.apply(errors, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(providerViewContext.errors)); - usedPipes.push.apply(usedPipes, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(bindingParser.getUsedPipes())); - } - else { - result = []; - } - this._assertNoReferenceDuplicationOnTemplate(result, errors); - if (errors.length > 0) { - return new TemplateParseResult(result, usedPipes, errors); - } - if (this.transforms) { - this.transforms.forEach(function (transform) { result = templateVisitAll(transform, result); }); - } - return new TemplateParseResult(result, usedPipes, errors); - }; - TemplateParser.prototype.expandHtml = function (htmlAstWithErrors, forced) { - if (forced === void 0) { forced = false; } - var errors = htmlAstWithErrors.errors; - if (errors.length == 0 || forced) { - // Transform ICU messages to angular directives - var expandedHtmlAst = expandNodes(htmlAstWithErrors.rootNodes); - errors.push.apply(errors, Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"])(expandedHtmlAst.errors)); - htmlAstWithErrors = new ParseTreeResult(expandedHtmlAst.nodes, errors); - } - return htmlAstWithErrors; - }; - TemplateParser.prototype.getInterpolationConfig = function (component) { - if (component.template) { - return InterpolationConfig.fromArray(component.template.interpolation); - } - return undefined; - }; - /** @internal */ - TemplateParser.prototype._assertNoReferenceDuplicationOnTemplate = function (result, errors) { - var existingReferences = []; - result.filter(function (element) { return !!element.references; }) - .forEach(function (element) { return element.references.forEach(function (reference) { - var name = reference.name; - if (existingReferences.indexOf(name) < 0) { - existingReferences.push(name); - } - else { - var error = new TemplateParseError("Reference \"#" + name + "\" is defined several times", reference.sourceSpan, ParseErrorLevel.ERROR); - errors.push(error); - } - }); }); - }; - return TemplateParser; -}()); -var TemplateParseVisitor = /** @class */ (function () { - function TemplateParseVisitor(reflector, config, providerViewContext, directives, _bindingParser, _schemaRegistry, _schemas, _targetErrors) { - var _this = this; - this.reflector = reflector; - this.config = config; - this.providerViewContext = providerViewContext; - this._bindingParser = _bindingParser; - this._schemaRegistry = _schemaRegistry; - this._schemas = _schemas; - this._targetErrors = _targetErrors; - this.selectorMatcher = new SelectorMatcher(); - this.directivesIndex = new Map(); - this.ngContentCount = 0; - // Note: queries start with id 1 so we can use the number in a Bloom filter! - this.contentQueryStartId = providerViewContext.component.viewQueries.length + 1; - directives.forEach(function (directive, index) { - var selector = CssSelector.parse(directive.selector); - _this.selectorMatcher.addSelectables(selector, directive); - _this.directivesIndex.set(directive, index); - }); - } - TemplateParseVisitor.prototype.visitExpansion = function (expansion, context) { return null; }; - TemplateParseVisitor.prototype.visitExpansionCase = function (expansionCase, context) { return null; }; - TemplateParseVisitor.prototype.visitText = function (text, parent) { - var ngContentIndex = parent.findNgContentIndex(TEXT_CSS_SELECTOR()); - var valueNoNgsp = replaceNgsp(text.value); - var expr = this._bindingParser.parseInterpolation(valueNoNgsp, text.sourceSpan); - return expr ? new BoundTextAst(expr, ngContentIndex, text.sourceSpan) : - new TextAst(valueNoNgsp, ngContentIndex, text.sourceSpan); - }; - TemplateParseVisitor.prototype.visitAttribute = function (attribute, context) { - return new AttrAst(attribute.name, attribute.value, attribute.sourceSpan); - }; - TemplateParseVisitor.prototype.visitComment = function (comment, context) { return null; }; - TemplateParseVisitor.prototype.visitElement = function (element, parent) { - var _this = this; - var queryStartIndex = this.contentQueryStartId; - var elName = element.name; - var preparsedElement = preparseElement(element); - if (preparsedElement.type === PreparsedElementType.SCRIPT || - preparsedElement.type === PreparsedElementType.STYLE) { - // Skipping