@angular-wave/angular.ts 0.7.0-beta.0 → 0.7.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.husky/pre-commit +2 -0
- package/@types/animations/animate-children-directive.d.ts +4 -2
- package/@types/animations/animate-swap.d.ts +2 -2
- package/@types/animations/animate.d.ts +1 -1
- package/@types/animations/interface.d.ts +17 -0
- package/@types/animations/raf-scheduler.d.ts +29 -16
- package/@types/core/compile/attributes.d.ts +1 -1
- package/@types/core/compile/compile.d.ts +22 -15
- package/@types/core/controller/controller.d.ts +1 -1
- package/@types/core/di/internal-injector.d.ts +10 -6
- package/@types/core/di/ng-module.d.ts +3 -3
- package/@types/core/error-handler.d.ts +7 -0
- package/@types/core/exception-handler.d.ts +5 -10
- package/@types/core/filter/filter.d.ts +20 -4
- package/@types/core/interpolate/interpolate.d.ts +3 -3
- package/@types/core/location/location.d.ts +1 -1
- package/@types/core/parse/interface.d.ts +79 -0
- package/@types/core/parse/interpreter.d.ts +19 -8
- package/@types/core/parse/parse.d.ts +2 -94
- package/@types/core/parse/parser/parser.d.ts +2 -2
- package/@types/core/sanitize/interface.d.ts +10 -0
- package/@types/core/sanitize/sanitize-uri.d.ts +31 -44
- package/@types/core/sce/sce.d.ts +109 -32
- package/@types/core/scope/scope.d.ts +3 -3
- package/@types/directive/bind/bind.d.ts +6 -6
- package/@types/directive/channel/channel.d.ts +2 -2
- package/@types/directive/class/class.d.ts +3 -3
- package/@types/directive/cloak/cloak.d.ts +2 -2
- package/@types/directive/controller/controller.d.ts +2 -2
- package/@types/directive/events/events.d.ts +4 -4
- package/@types/directive/form/form.d.ts +1 -1
- package/@types/directive/if/if.d.ts +2 -2
- package/@types/directive/include/include.d.ts +2 -2
- package/@types/directive/init/init.d.ts +2 -2
- package/@types/directive/input/input.d.ts +4 -4
- package/@types/directive/model/model.d.ts +10 -10
- package/@types/directive/model-options/model-options.d.ts +1 -1
- package/@types/directive/non-bindable/non-bindable.d.ts +2 -2
- package/@types/directive/observe/observe.d.ts +2 -2
- package/@types/directive/options/options.d.ts +1 -1
- package/@types/directive/repeat/repeat.d.ts +2 -2
- package/@types/directive/script/script.d.ts +2 -2
- package/@types/directive/select/select.d.ts +2 -2
- package/@types/directive/setter/setter.d.ts +6 -3
- package/@types/directive/show-hide/show-hide.d.ts +4 -4
- package/@types/directive/style/style.d.ts +2 -2
- package/@types/directive/switch/switch.d.ts +6 -6
- package/@types/directive/transclude/transclude.d.ts +3 -1
- package/@types/directive/validators/validators.d.ts +14 -14
- package/@types/filters/filter.d.ts +2 -7
- package/@types/filters/filters.d.ts +2 -2
- package/@types/filters/limit-to.d.ts +2 -6
- package/@types/filters/order-by.d.ts +4 -3
- package/@types/interface.d.ts +302 -0
- package/@types/loader.d.ts +15 -18
- package/@types/public.d.ts +6 -7
- package/@types/router/common/glob.d.ts +25 -8
- package/@types/router/common/queue.d.ts +62 -13
- package/@types/router/common/trace.d.ts +8 -14
- package/@types/router/directives/state-directives.d.ts +11 -10
- package/@types/router/directives/view-directive.d.ts +3 -3
- package/@types/router/globals.d.ts +25 -7
- package/@types/router/params/interface.d.ts +606 -0
- package/@types/router/resolve/interface.d.ts +200 -0
- package/@types/router/state/interface.d.ts +983 -0
- package/@types/router/state/state-object.d.ts +13 -3
- package/@types/router/state/state-registry.d.ts +18 -4
- package/@types/router/state/state-service.d.ts +18 -10
- package/@types/router/state/views.d.ts +14 -8
- package/@types/router/state-filters.d.ts +8 -4
- package/@types/router/template-factory.d.ts +4 -4
- package/@types/router/transition/interface.d.ts +876 -11
- package/@types/router/transition/transition-service.d.ts +3 -3
- package/@types/router/transition/transition.d.ts +25 -15
- package/@types/router/view/interface.d.ts +44 -0
- package/@types/router/view/view.d.ts +17 -5
- package/@types/shared/interface.d.ts +6 -0
- package/@types/shared/utils.d.ts +18 -33
- package/CHANGELOG.md +38 -38
- package/CODE_OF_CONDUCT.md +1 -1
- package/CONTRIBUTING.md +9 -9
- package/DEVELOPERS.md +30 -30
- package/Makefile +1 -1
- package/README.md +20 -20
- package/RELEASE.md +3 -3
- package/SECURITY.md +1 -1
- package/TRIAGING.md +3 -3
- package/dist/angular-ts.esm.js +3853 -3514
- package/dist/angular-ts.umd.js +3854 -3514
- package/dist/angular-ts.umd.min.js +1 -1
- package/index.html +2 -11
- package/package.json +3 -3
- package/src/angular.spec.js +1 -99
- package/src/animations/animate-children-directive.js +2 -2
- package/src/animations/animate-css.md +1 -1
- package/src/animations/animate-queue.js +1 -1
- package/src/animations/animate-swap.js +20 -17
- package/src/animations/animate.js +1 -1
- package/src/animations/animate.md +8 -8
- package/src/animations/animation.js +1 -0
- package/src/animations/interface.ts +19 -0
- package/src/animations/raf-scheduler.js +70 -54
- package/src/animations/raf-scheduler.spec.js +6 -0
- package/src/core/compile/attributes.js +13 -15
- package/src/core/compile/compile.js +2737 -2631
- package/src/core/compile/compile.md +13 -13
- package/src/core/compile/compile.spec.js +8 -108
- package/src/core/controller/controller.js +1 -1
- package/src/core/di/injector.js +34 -6
- package/src/core/di/injector.md +6 -6
- package/src/core/di/internal-injector.js +19 -21
- package/src/core/di/ng-module.js +4 -3
- package/src/core/error-handler.ts +7 -0
- package/src/core/exception-handler.js +4 -9
- package/src/core/filter/filter.js +12 -3
- package/src/core/filter/filter.md +5 -5
- package/src/core/interpolate/interpolate.js +6 -6
- package/src/core/interpolate/interpolate.spec.js +1 -1
- package/src/core/location/location.js +3 -3
- package/src/core/parse/ast/ast.js +2 -2
- package/src/core/parse/interface.ts +84 -0
- package/src/core/parse/interpreter.js +33 -28
- package/src/core/parse/parse.js +8 -55
- package/src/core/parse/parse.md +6 -6
- package/src/core/parse/parser/parser.js +1 -1
- package/src/core/sanitize/interface.ts +10 -0
- package/src/core/sanitize/sanitize-uri.js +46 -56
- package/src/core/sanitize/sanitize-uri.spec.js +1 -1
- package/src/core/sce/sce.js +378 -301
- package/src/core/sce/sce.md +13 -13
- package/src/core/scope/scope.js +8 -6
- package/src/directive/aria/aria.js +9 -11
- package/src/directive/attrs/attrs.md +7 -7
- package/src/directive/bind/bind.js +5 -5
- package/src/directive/bind/bind.md +3 -3
- package/src/directive/channel/channel.js +1 -1
- package/src/directive/class/class.js +1 -1
- package/src/directive/cloak/cloak.js +1 -1
- package/src/directive/cloak/cloak.md +1 -1
- package/src/directive/controller/controller.js +1 -1
- package/src/directive/controller/controller.md +2 -2
- package/src/directive/events/events.js +3 -3
- package/src/directive/events/events.md +2 -2
- package/src/directive/form/form.js +5 -5
- package/src/directive/if/if.js +1 -1
- package/src/directive/include/include.js +1 -1
- package/src/directive/include/include.md +2 -2
- package/src/directive/init/init.js +1 -1
- package/src/directive/input/input.js +7 -7
- package/src/directive/input/input.md +54 -54
- package/src/directive/messages/messages.js +2 -2
- package/src/directive/messages/messages.md +2 -2
- package/src/directive/model/model.js +3 -3
- package/src/directive/model-options/model-options.js +3 -3
- package/src/directive/model-options/model-options.md +1 -1
- package/src/directive/non-bindable/non-bindable.js +1 -1
- package/src/directive/non-bindable/non-bindable.md +1 -1
- package/src/directive/observe/observe.js +1 -1
- package/src/directive/options/options.js +3 -5
- package/src/directive/options/options.md +1 -1
- package/src/directive/ref/ref.js +9 -4
- package/src/directive/repeat/repeat.js +7 -8
- package/src/directive/repeat/repeat.md +3 -3
- package/src/directive/script/script.js +3 -3
- package/src/directive/select/select.js +2 -2
- package/src/directive/select/select.md +3 -3
- package/src/directive/setter/setter.js +8 -6
- package/src/directive/show-hide/show-hide.js +2 -2
- package/src/directive/show-hide/show-hide.md +4 -4
- package/src/directive/style/style.js +2 -2
- package/src/directive/switch/switch.js +6 -6
- package/src/directive/transclude/transclude.js +2 -2
- package/src/directive/validators/validators.js +37 -36
- package/src/filters/filter.js +1 -1
- package/src/filters/filters.js +1 -1
- package/src/filters/limit-to.js +1 -1
- package/src/filters/order-by.js +3 -0
- package/src/filters/order-by.md +1 -1
- package/src/interface.ts +329 -0
- package/src/loader.js +20 -19
- package/src/loader.md +7 -7
- package/src/public.js +5 -7
- package/src/router/common/{glob.html → common.html} +1 -0
- package/src/router/common/{glob.test.js → common.test.js} +1 -1
- package/src/router/common/glob.js +29 -7
- package/src/router/common/glob.spec.js +31 -1
- package/src/router/common/queue.js +69 -14
- package/src/router/common/queue.spec.js +80 -0
- package/src/router/common/trace.js +21 -15
- package/src/router/directives/component-example.html +37 -0
- package/src/router/directives/state-directives.js +13 -12
- package/src/router/directives/state-directives.spec.js +51 -46
- package/src/router/directives/view-directive.js +6 -6
- package/src/router/directives/view-directive.spec.js +1 -1
- package/src/router/globals.js +24 -5
- package/src/router/hooks/update-globals.js +2 -0
- package/src/router/params/interface.ts +626 -0
- package/src/router/params/param-types.js +2 -2
- package/src/router/resolve/interface.ts +208 -0
- package/src/router/resolve/resolvable.js +2 -2
- package/src/router/state/interface.ts +1007 -0
- package/src/router/state/state-builder.js +2 -2
- package/src/router/state/state-object.js +19 -5
- package/src/router/state/state-queue-manager.js +3 -5
- package/src/router/state/state-registry.js +14 -3
- package/src/router/state/state-service.js +14 -8
- package/src/router/state/views.js +9 -4
- package/src/router/state-filters.js +6 -0
- package/src/router/template-factory.js +2 -2
- package/src/router/transition/interface.ts +922 -0
- package/src/router/transition/transition-service.js +1 -1
- package/src/router/transition/transition.js +17 -7
- package/src/router/url/url-matcher.js +2 -2
- package/src/router/view/interface.ts +51 -0
- package/src/router/view/view.js +17 -10
- package/src/router/view/view.spec.js +2 -2
- package/src/services/http/http.md +8 -8
- package/src/services/log.md +1 -1
- package/src/services/template-request.js +1 -1
- package/src/shared/dom.js +2 -2
- package/src/shared/interface.ts +6 -0
- package/src/shared/utils.js +22 -37
- package/tsconfig.json +2 -1
- package/tsconfig.types.json +1 -0
- package/typedoc/assets/hierarchy.js +1 -1
- package/typedoc/assets/navigation.js +1 -1
- package/typedoc/assets/search.js +1 -1
- package/typedoc/classes/animations_animate-cache.AnimateCacheProvider.html +6 -6
- package/typedoc/classes/animations_animate-css-driver.AnimateCssDriverProvider.html +10 -10
- package/typedoc/classes/animations_animate-css.AnimateCssProvider.html +10 -10
- package/typedoc/classes/animations_animate-js-driver.AnimateJsDriverProvider.html +10 -10
- package/typedoc/classes/animations_animate-js.AnimateJsProvider.html +10 -10
- package/typedoc/classes/animations_animate-queue.AnimateQueueProvider.html +12 -12
- package/typedoc/classes/animations_animate-runner.AnimateAsyncRunFactoryProvider.html +6 -6
- package/typedoc/classes/animations_animate-runner.AnimateRunner.html +48 -48
- package/typedoc/classes/animations_animate-runner.AnimateRunnerFactoryProvider.html +6 -6
- package/typedoc/classes/animations_animate.AnimateProvider.html +18 -18
- package/typedoc/classes/animations_animation.AnimationProvider.html +12 -12
- package/typedoc/classes/animations_raf-scheduler.RafSchedulerProvider.html +323 -52
- package/typedoc/classes/core_cache_cache-factory.TemplateCacheProvider.html +4 -4
- package/typedoc/classes/core_compile_attributes.Attributes.html +43 -43
- package/typedoc/classes/core_compile_compile.CompileProvider.html +51 -43
- package/typedoc/classes/core_controller_controller.ControllerProvider.html +13 -13
- package/typedoc/classes/core_di_internal-injector.InjectorService.html +34 -32
- package/typedoc/classes/core_di_internal-injector.ProviderInjector.html +25 -25
- package/typedoc/classes/core_di_ng-module.NgModule.html +50 -50
- package/typedoc/classes/core_exception-handler.ExceptionHandlerProvider.html +17 -17
- package/typedoc/classes/core_filter_filter.FilterProvider.html +156 -21
- package/typedoc/classes/core_interpolate_interpolate.InterpolateProvider.html +22 -22
- package/typedoc/classes/core_location_location.Location.html +76 -76
- package/typedoc/classes/core_location_location.LocationHashbangUrl.html +78 -78
- package/typedoc/classes/core_location_location.LocationHtml5Url.html +78 -78
- package/typedoc/classes/core_location_location.LocationProvider.html +20 -20
- package/typedoc/classes/core_parse_ast_ast.AST.html +64 -64
- package/typedoc/classes/core_parse_interpreter.ASTInterpreter.html +112 -78
- package/typedoc/classes/core_parse_lexer_lexer.Lexer.html +42 -42
- package/typedoc/classes/core_parse_parse.ParseProvider.html +13 -14
- package/typedoc/classes/core_parse_parser_parser.Parser.html +14 -14
- package/typedoc/classes/core_pubsub_pubsub.PubSub.html +26 -26
- package/typedoc/classes/core_sanitize_sanitize-uri.SanitizeUriProvider.html +205 -319
- package/typedoc/classes/core_sce_sce.SceDelegateProvider.html +18 -85
- package/typedoc/classes/core_sce_sce.SceProvider.html +8 -8
- package/typedoc/classes/core_scope_scope.RootScopeProvider.html +10 -10
- package/typedoc/classes/core_scope_scope.Scope.html +110 -193
- package/typedoc/classes/core_task-tracker-factory.TaskTracker.html +14 -14
- package/typedoc/classes/core_task-tracker-factory.TaskTrackerFactoryProvider.html +4 -4
- package/typedoc/classes/directive_aria_aria.AriaProvider.html +8 -8
- package/typedoc/classes/directive_form_form.FormController.html +85 -85
- package/typedoc/classes/directive_model_model.NgModelController.html +213 -213
- package/typedoc/classes/loader.Angular.html +58 -62
- package/typedoc/classes/router_common_glob.Glob.html +208 -101
- package/typedoc/classes/router_common_queue.Queue.html +279 -68
- package/typedoc/classes/router_common_trace.Trace.html +44 -44
- package/typedoc/classes/router_globals.RouterGlobals.html +937 -0
- package/typedoc/classes/router_params_param-factory.ParamFactory.html +12 -12
- package/typedoc/classes/router_params_param-type.ParamType.html +26 -26
- package/typedoc/classes/router_params_param-types.ParamTypes.html +16 -16
- package/typedoc/classes/router_params_param.Param.html +46 -46
- package/typedoc/classes/router_params_state-params.StateParams.html +6 -6
- package/typedoc/classes/router_path_path-node.PathNode.html +34 -34
- package/typedoc/classes/router_path_path-utils.PathUtils.html +22 -22
- package/typedoc/classes/router_resolve_resolvable.Resolvable.html +54 -54
- package/typedoc/classes/router_resolve_resolve-context.ResolveContext.html +26 -26
- package/typedoc/classes/router_state-provider.StateProvider.html +14 -14
- package/typedoc/classes/router_state_state-builder.StateBuilder.html +18 -18
- package/typedoc/classes/router_state_state-matcher.StateMatcher.html +12 -12
- package/typedoc/classes/router_state_state-object.StateObject.html +202 -45
- package/typedoc/classes/router_state_state-queue-manager.StateQueueManager.html +22 -22
- package/typedoc/classes/router_state_state-registry.StateRegistryProvider.html +76 -133
- package/typedoc/classes/router_state_state-service.StateProvider.html +120 -72
- package/typedoc/classes/router_state_target-state.TargetState.html +46 -46
- package/typedoc/classes/{router_state_views.Ng1ViewConfig.html → router_state_views.ViewConfig.html} +83 -51
- package/typedoc/classes/router_template-factory.TemplateFactoryProvider.html +36 -62
- package/typedoc/classes/router_transition_hook-builder.HookBuilder.html +21 -14
- package/typedoc/classes/router_transition_hook-registry.RegisteredHook.html +36 -36
- package/typedoc/classes/router_transition_reject-factory.Rejection.html +32 -32
- package/typedoc/classes/router_transition_transition-event-type.TransitionEventType.html +20 -20
- package/typedoc/classes/router_transition_transition-hook.TransitionHook.html +54 -54
- package/typedoc/classes/router_transition_transition-service.TransitionProvider.html +48 -48
- package/typedoc/classes/router_transition_transition.Transition.html +597 -145
- package/typedoc/classes/router_url_url-config.UrlConfigProvider.html +28 -28
- package/typedoc/classes/router_url_url-matcher.UrlMatcher.html +50 -50
- package/typedoc/classes/router_url_url-rule.BaseUrlRule.html +16 -16
- package/typedoc/classes/router_url_url-rule.UrlRuleFactory.html +22 -22
- package/typedoc/classes/router_url_url-rules.UrlRules.html +42 -42
- package/typedoc/classes/router_url_url-service.UrlService.html +68 -68
- package/typedoc/classes/router_view-scroll.ViewScrollProvider.html +12 -12
- package/typedoc/classes/router_view_view.ViewService.html +228 -212
- package/typedoc/classes/services_anchor-scroll.AnchorScrollProvider.html +12 -12
- package/typedoc/classes/services_browser.Browser.html +54 -54
- package/typedoc/classes/services_browser.BrowserProvider.html +4 -4
- package/typedoc/classes/services_http-backend_http-backend.HttpBackendProvider.html +6 -6
- package/typedoc/classes/services_http_http.HttpParamSerializerProvider.html +6 -6
- package/typedoc/classes/services_http_http.HttpProvider.html +14 -14
- package/typedoc/classes/services_log.LogProvider.html +16 -16
- package/typedoc/classes/services_template-request.TemplateRequestProvider.html +12 -12
- package/typedoc/classes/shared_noderef.NodeRef.html +60 -60
- package/typedoc/enums/core_parse_ast-type.ASTType.html +38 -38
- package/typedoc/enums/router_common_trace.Category.html +568 -0
- package/typedoc/enums/router_transition_interface.TransitionHookPhase.html +18 -33
- package/typedoc/{interfaces/types.ServiceProviderClass.html → enums/router_transition_interface.TransitionHookScope.html} +75 -44
- package/typedoc/enums/router_transition_reject-factory.RejectType.html +14 -14
- package/typedoc/functions/animations_animate-cache.animateCache.html +14 -14
- package/typedoc/functions/animations_animate-children-directive.__AnimateChildrenDirective.html +6 -6
- package/typedoc/functions/animations_animate-swap.ngAnimateSwapDirective.html +6 -6
- package/typedoc/functions/animations_shared.applyAnimationClassesFactory.html +2 -2
- package/typedoc/functions/animations_shared.applyAnimationFromStyles.html +2 -2
- package/typedoc/functions/animations_shared.applyAnimationStyles.html +2 -2
- package/typedoc/functions/animations_shared.applyAnimationToStyles.html +2 -2
- package/typedoc/functions/animations_shared.applyGeneratedPreparationClasses.html +2 -2
- package/typedoc/functions/animations_shared.applyInlineStyle.html +2 -2
- package/typedoc/functions/animations_shared.assertArg.html +2 -2
- package/typedoc/functions/animations_shared.blockKeyframeAnimations.html +2 -2
- package/typedoc/functions/animations_shared.clearGeneratedClasses.html +2 -2
- package/typedoc/functions/animations_shared.concatWithSpace.html +2 -2
- package/typedoc/functions/animations_shared.extractElementNode.html +2 -2
- package/typedoc/functions/animations_shared.mergeAnimationDetails.html +2 -2
- package/typedoc/functions/animations_shared.mergeClasses.html +2 -2
- package/typedoc/functions/animations_shared.packageStyles.html +2 -2
- package/typedoc/functions/animations_shared.pendClasses.html +2 -2
- package/typedoc/functions/animations_shared.prepareAnimationOptions.html +2 -2
- package/typedoc/functions/animations_shared.removeFromArray.html +2 -2
- package/typedoc/functions/animations_shared.resolveElementClasses.html +2 -2
- package/typedoc/functions/animations_shared.stripCommentsFromElement.html +2 -2
- package/typedoc/functions/core_controller_controller.identifierForController.html +2 -2
- package/typedoc/functions/core_di_injector.annotate.html +2 -2
- package/typedoc/functions/core_di_injector.createInjector.html +2 -2
- package/typedoc/functions/core_location_location.serverBase.html +2 -2
- package/typedoc/functions/core_location_location.stripBaseUrl.html +2 -2
- package/typedoc/functions/core_location_location.stripFile.html +2 -2
- package/typedoc/functions/core_location_location.stripHash.html +2 -2
- package/typedoc/functions/core_parse_interpreter.isAssignable.html +2 -2
- package/typedoc/functions/core_parse_parse.constantWatchDelegate.html +2 -2
- package/typedoc/functions/core_sce_sce.adjustMatcher.html +2 -2
- package/typedoc/functions/core_sce_sce.escapeForRegexp.html +2 -2
- package/typedoc/functions/core_scope_scope.createScope.html +2 -2
- package/typedoc/functions/core_scope_scope.nextId.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.getBaseUrl.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.urlIsAllowedOriginFactory.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.urlIsSameOrigin.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.urlIsSameOriginAsBaseUrl.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.urlResolve.html +2 -2
- package/typedoc/functions/core_url-utils_url-utils.urlsAreSameOrigin.html +2 -2
- package/typedoc/functions/directive_aria_aria.ngCheckedAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngClickAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngDblclickAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngDisabledAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngHideAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngMessagesAriaDirective.html +2 -2
- package/typedoc/functions/directive_aria_aria.ngModelAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngReadonlyAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngRequiredAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngShowAriaDirective.html +4 -4
- package/typedoc/functions/directive_aria_aria.ngValueAriaDirective.html +4 -4
- package/typedoc/functions/directive_bind_bind.ngBindDirective.html +4 -4
- package/typedoc/functions/directive_bind_bind.ngBindHtmlDirective.html +6 -6
- package/typedoc/functions/directive_bind_bind.ngBindTemplateDirective.html +4 -4
- package/typedoc/functions/directive_channel_channel.ngChannelDirective.html +4 -4
- package/typedoc/functions/directive_cloak_cloak.ngCloakDirective.html +4 -4
- package/typedoc/functions/directive_controller_controller.ngControllerDirective.html +4 -4
- package/typedoc/functions/directive_events_events.createEventDirective.html +8 -8
- package/typedoc/functions/directive_form_form.setupValidity.html +2 -2
- package/typedoc/functions/directive_if_if.ngIfDirective.html +6 -6
- package/typedoc/functions/directive_include_include.ngIncludeDirective.html +4 -4
- package/typedoc/functions/directive_include_include.ngIncludeFillContentDirective.html +6 -6
- package/typedoc/functions/directive_init_init.ngInitDirective.html +4 -4
- package/typedoc/functions/directive_input_input.badInputChecker.html +2 -2
- package/typedoc/functions/directive_input_input.countDecimals.html +2 -2
- package/typedoc/functions/directive_input_input.createDateInputType.html +2 -2
- package/typedoc/functions/directive_input_input.createDateParser.html +2 -2
- package/typedoc/functions/directive_input_input.hiddenInputBrowserCacheDirective.html +4 -4
- package/typedoc/functions/directive_input_input.inputDirective.html +4 -4
- package/typedoc/functions/directive_input_input.isNumberInteger.html +2 -2
- package/typedoc/functions/directive_input_input.isValidForStep.html +2 -2
- package/typedoc/functions/directive_input_input.ngValueDirective.html +4 -4
- package/typedoc/functions/directive_input_input.numberFormatterParser.html +2 -2
- package/typedoc/functions/directive_input_input.numberInputType.html +2 -2
- package/typedoc/functions/directive_input_input.rangeInputType.html +2 -2
- package/typedoc/functions/directive_input_input.weekParser.html +2 -2
- package/typedoc/functions/directive_messages_messages.ngMessagesDirective.html +4 -4
- package/typedoc/functions/directive_messages_messages.ngMessagesIncludeDirective.html +4 -4
- package/typedoc/functions/directive_model-options_model-options.ngModelOptionsDirective.html +4 -4
- package/typedoc/functions/directive_model_model.ngModelDirective.html +2 -2
- package/typedoc/functions/directive_non-bindable_non-bindable.ngNonBindableDirective.html +4 -4
- package/typedoc/functions/directive_observe_observe.ngObserveDirective.html +4 -4
- package/typedoc/functions/directive_ref_ref.ngRefDirective.html +4 -4
- package/typedoc/functions/directive_repeat_repeat.ngRepeatDirective.html +6 -6
- package/typedoc/functions/directive_script_script.scriptDirective.html +6 -6
- package/typedoc/functions/directive_select_select.optionDirective.html +4 -4
- package/typedoc/functions/directive_select_select.selectDirective.html +4 -4
- package/typedoc/functions/directive_setter_setter.ngSetterDirective.html +34 -8
- package/typedoc/functions/directive_show-hide_show-hide.ngHideDirective.html +6 -6
- package/typedoc/functions/directive_show-hide_show-hide.ngShowDirective.html +6 -6
- package/typedoc/functions/directive_style_style.ngStyleDirective.html +4 -4
- package/typedoc/functions/directive_switch_switch.ngSwitchDefaultDirective.html +4 -4
- package/typedoc/functions/directive_switch_switch.ngSwitchDirective.html +6 -6
- package/typedoc/functions/directive_switch_switch.ngSwitchWhenDirective.html +4 -4
- package/typedoc/functions/filters_filter.filterFilter.html +11 -76
- package/typedoc/functions/filters_filters.formatNumber.html +2 -2
- package/typedoc/functions/filters_filters.jsonFilter.html +12 -24
- package/typedoc/functions/filters_limit-to.limitToFilter.html +11 -90
- package/typedoc/functions/filters_order-by.orderByFilter.html +18 -55
- package/typedoc/functions/public.publishExternalAPI.html +8 -8
- package/typedoc/functions/router_common_glob.hasGlobs.html +306 -0
- package/typedoc/functions/router_directives_state-directives._StateRefActiveDirective.html +15 -8
- package/typedoc/functions/router_directives_state-directives._StateRefDirective.html +4 -4
- package/typedoc/functions/router_directives_state-directives._StateRefDynamicDirective.html +17 -77
- package/typedoc/functions/router_directives_view-directive._ViewDirectiveFill.html +4 -4
- package/typedoc/functions/router_hooks_core-resolvables.registerAddCoreResolvables.html +2 -2
- package/typedoc/functions/router_hooks_core-resolvables.treeChangesCleanup.html +2 -2
- package/typedoc/functions/router_hooks_ignored-transition.registerIgnoredTransitionHook.html +2 -2
- package/typedoc/functions/router_hooks_invalid-transition.registerInvalidTransitionHook.html +2 -2
- package/typedoc/functions/router_hooks_lazy-load.lazyLoadState.html +2 -2
- package/typedoc/functions/router_hooks_lazy-load.registerLazyLoadHook.html +2 -2
- package/typedoc/functions/router_hooks_on-enter-exit-retain.registerOnEnterHook.html +2 -2
- package/typedoc/functions/router_hooks_on-enter-exit-retain.registerOnExitHook.html +2 -2
- package/typedoc/functions/router_hooks_on-enter-exit-retain.registerOnRetainHook.html +2 -2
- package/typedoc/functions/router_hooks_redirect-to.registerRedirectToHook.html +2 -2
- package/typedoc/functions/router_hooks_resolve.registerEagerResolvePath.html +2 -2
- package/typedoc/functions/router_hooks_resolve.registerLazyResolveState.html +2 -2
- package/typedoc/functions/router_hooks_resolve.registerResolveRemaining.html +2 -2
- package/typedoc/functions/router_hooks_update-globals.registerUpdateGlobalState.html +2 -2
- package/typedoc/functions/router_hooks_url.registerUpdateUrl.html +2 -2
- package/typedoc/functions/router_hooks_views.registerActivateViews.html +2 -2
- package/typedoc/functions/router_hooks_views.registerLoadEnteringViews.html +2 -2
- package/typedoc/functions/router_path_path-utils.makeTargetState.html +2 -2
- package/typedoc/functions/router_state-filters._IncludedByStateFilter.html +18 -40
- package/typedoc/functions/router_state-filters._IsStateFilter.html +15 -34
- package/typedoc/functions/router_state_state-builder.resolvablesBuilder.html +2 -2
- package/typedoc/functions/router_state_state-registry.getLocals.html +2 -2
- package/typedoc/functions/{router_state_views.getNg1ViewConfigFactory.html → router_state_views.getViewConfigFactory.html} +13 -15
- package/typedoc/functions/router_state_views.ng1ViewsBuilder.html +2 -2
- package/typedoc/functions/router_transition_hook-registry.makeEvent.html +2 -2
- package/typedoc/functions/router_transition_hook-registry.matchState.html +2 -2
- package/typedoc/functions/services_browser.trimEmptyHash.html +2 -2
- package/typedoc/functions/services_cookie-reader.getCookies.html +2 -2
- package/typedoc/functions/services_http-backend_http-backend.createHttpBackend.html +2 -2
- package/typedoc/functions/services_http_http.defaultHttpResponseTransform.html +2 -2
- package/typedoc/functions/shared_common._removeFrom.html +2 -2
- package/typedoc/functions/shared_common.allTrueR.html +2 -2
- package/typedoc/functions/shared_common.ancestors.html +2 -2
- package/typedoc/functions/shared_common.anyTrueR.html +2 -2
- package/typedoc/functions/shared_common.applyPairs.html +2 -2
- package/typedoc/functions/shared_common.arrayTuples.html +2 -2
- package/typedoc/functions/shared_common.assertFn.html +2 -2
- package/typedoc/functions/shared_common.copy.html +2 -2
- package/typedoc/functions/shared_common.createProxyFunctions.html +2 -2
- package/typedoc/functions/shared_common.defaults.html +2 -2
- package/typedoc/functions/shared_common.deregAll.html +2 -2
- package/typedoc/functions/shared_common.equals.html +2 -2
- package/typedoc/functions/shared_common.filter.html +2 -2
- package/typedoc/functions/shared_common.find.html +2 -2
- package/typedoc/functions/shared_common.flatten.html +2 -2
- package/typedoc/functions/shared_common.flattenR.html +2 -2
- package/typedoc/functions/shared_common.inherit.html +2 -2
- package/typedoc/functions/shared_common.map.html +2 -2
- package/typedoc/functions/shared_common.omit.html +2 -2
- package/typedoc/functions/shared_common.pairs.html +2 -2
- package/typedoc/functions/shared_common.pick.html +2 -2
- package/typedoc/functions/shared_common.pushR.html +2 -2
- package/typedoc/functions/shared_common.silenceUncaughtInPromise.html +2 -2
- package/typedoc/functions/shared_common.silentRejection.html +2 -2
- package/typedoc/functions/shared_common.tail.html +2 -2
- package/typedoc/functions/shared_common.uniqR.html +2 -2
- package/typedoc/functions/shared_common.unnest.html +2 -2
- package/typedoc/functions/shared_common.unnestR.html +2 -2
- package/typedoc/functions/shared_dom.appendNodesToElement.html +2 -2
- package/typedoc/functions/shared_dom.buildFragment.html +2 -2
- package/typedoc/functions/shared_dom.cleanElementData.html +2 -2
- package/typedoc/functions/shared_dom.createElementFromHTML.html +2 -2
- package/typedoc/functions/shared_dom.createNodelistFromHTML.html +2 -2
- package/typedoc/functions/shared_dom.dealoc.html +2 -2
- package/typedoc/functions/shared_dom.deleteCacheData.html +2 -2
- package/typedoc/functions/shared_dom.domInsert.html +2 -2
- package/typedoc/functions/shared_dom.emptyElement.html +2 -2
- package/typedoc/functions/shared_dom.getBlockNodes.html +2 -2
- package/typedoc/functions/shared_dom.getBooleanAttrName.html +2 -2
- package/typedoc/functions/shared_dom.getCacheData.html +2 -2
- package/typedoc/functions/shared_dom.getController.html +2 -2
- package/typedoc/functions/shared_dom.getExpando.html +2 -2
- package/typedoc/functions/shared_dom.getInheritedData.html +2 -2
- package/typedoc/functions/shared_dom.getInjector.html +2 -2
- package/typedoc/functions/shared_dom.getIsolateScope.html +2 -2
- package/typedoc/functions/shared_dom.getOrSetCacheData.html +2 -2
- package/typedoc/functions/shared_dom.getScope.html +2 -2
- package/typedoc/functions/shared_dom.isRoot.html +2 -2
- package/typedoc/functions/shared_dom.isTextNode.html +2 -2
- package/typedoc/functions/shared_dom.kebabToCamel.html +2 -2
- package/typedoc/functions/shared_dom.parseHtml.html +2 -2
- package/typedoc/functions/shared_dom.removeElement.html +2 -2
- package/typedoc/functions/shared_dom.removeElementData.html +2 -2
- package/typedoc/functions/shared_dom.setCacheData.html +2 -2
- package/typedoc/functions/shared_dom.setInheritedData.html +2 -2
- package/typedoc/functions/shared_dom.setIsolateScope.html +2 -2
- package/typedoc/functions/shared_dom.setScope.html +2 -2
- package/typedoc/functions/shared_dom.snakeToCamel.html +2 -2
- package/typedoc/functions/shared_dom.startingTag.html +2 -2
- package/typedoc/functions/shared_hof.all.html +2 -2
- package/typedoc/functions/shared_hof.compose.html +2 -2
- package/typedoc/functions/shared_hof.curry.html +2 -2
- package/typedoc/functions/shared_hof.is.html +2 -2
- package/typedoc/functions/shared_hof.or.html +2 -2
- package/typedoc/functions/shared_hof.parse.html +2 -2
- package/typedoc/functions/shared_hof.pattern.html +2 -2
- package/typedoc/functions/shared_hof.pipe.html +2 -2
- package/typedoc/functions/shared_hof.val.html +2 -2
- package/typedoc/functions/shared_predicates.isInjectable.html +2 -2
- package/typedoc/functions/shared_predicates.isPromise.html +2 -2
- package/typedoc/functions/shared_strings.beforeAfterSubstr.html +2 -2
- package/typedoc/functions/shared_strings.fnToString.html +2 -2
- package/typedoc/functions/shared_strings.functionToString.html +2 -2
- package/typedoc/functions/shared_strings.joinNeighborsR.html +2 -2
- package/typedoc/functions/shared_strings.kebobString.html +2 -2
- package/typedoc/functions/shared_strings.maxLength.html +2 -2
- package/typedoc/functions/shared_strings.padString.html +2 -2
- package/typedoc/functions/shared_strings.splitOnDelim.html +2 -2
- package/typedoc/functions/shared_strings.stringify.html +2 -2
- package/typedoc/functions/shared_strings.stripLastPathElement.html +2 -2
- package/typedoc/functions/shared_strings.trimHashVal.html +2 -2
- package/typedoc/functions/shared_test-utils.bootstrap.html +2 -2
- package/typedoc/functions/shared_test-utils.browserTrigger.html +2 -2
- package/typedoc/functions/shared_test-utils.wait.html +2 -2
- package/typedoc/functions/shared_utils.addDateMinutes.html +2 -2
- package/typedoc/functions/shared_utils.arrayRemove.html +2 -2
- package/typedoc/functions/shared_utils.assert.html +2 -2
- package/typedoc/functions/shared_utils.assertArg.html +2 -2
- package/typedoc/functions/shared_utils.assertArgFn.html +2 -2
- package/typedoc/functions/shared_utils.assertNotHasOwnProperty.html +2 -2
- package/typedoc/functions/shared_utils.baseExtend.html +2 -2
- package/typedoc/functions/shared_utils.bind.html +2 -2
- package/typedoc/functions/shared_utils.concat.html +2 -2
- package/typedoc/functions/shared_utils.convertTimezoneToLocal.html +2 -2
- package/typedoc/functions/shared_utils.csp.html +2 -2
- package/typedoc/functions/shared_utils.directiveNormalize.html +2 -2
- package/typedoc/functions/shared_utils.encodeUriQuery.html +2 -2
- package/typedoc/functions/shared_utils.encodeUriSegment.html +2 -2
- package/typedoc/functions/shared_utils.equals.html +2 -2
- package/typedoc/functions/shared_utils.errorHandlingConfig.html +2 -2
- package/typedoc/functions/shared_utils.extend.html +3 -3
- package/typedoc/functions/shared_utils.fromJson.html +2 -2
- package/typedoc/functions/shared_utils.getNgAttribute.html +2 -2
- package/typedoc/functions/shared_utils.getNodeName.html +2 -2
- package/typedoc/functions/shared_utils.hasAnimate.html +2 -2
- package/typedoc/functions/shared_utils.hasCustomToString.html +2 -2
- package/typedoc/functions/{shared_utils.merge.html → shared_utils.hasOwn.html} +44 -91
- package/typedoc/functions/shared_utils.hashKey.html +2 -2
- package/typedoc/functions/shared_utils.includes.html +2 -2
- package/typedoc/functions/shared_utils.inherit.html +2 -2
- package/typedoc/functions/shared_utils.isArrayBuffer.html +2 -2
- package/typedoc/functions/shared_utils.isArrayLike.html +2 -2
- package/typedoc/functions/shared_utils.isBlankObject.html +2 -2
- package/typedoc/functions/shared_utils.isBlob.html +2 -2
- package/typedoc/functions/shared_utils.isBoolean.html +2 -2
- package/typedoc/functions/shared_utils.isDate.html +2 -2
- package/typedoc/functions/shared_utils.isDefined.html +2 -2
- package/typedoc/functions/shared_utils.isElement.html +2 -2
- package/typedoc/functions/shared_utils.isError.html +2 -2
- package/typedoc/functions/shared_utils.isFile.html +2 -2
- package/typedoc/functions/shared_utils.isFormData.html +2 -2
- package/typedoc/functions/shared_utils.isFunction.html +2 -2
- package/typedoc/functions/shared_utils.isNull.html +2 -2
- package/typedoc/functions/shared_utils.isNullOrUndefined.html +2 -2
- package/typedoc/functions/shared_utils.isNumber.html +2 -2
- package/typedoc/functions/shared_utils.isNumberNaN.html +2 -2
- package/typedoc/functions/shared_utils.isObject.html +2 -2
- package/typedoc/functions/shared_utils.isObjectEmpty.html +2 -2
- package/typedoc/functions/shared_utils.isPromiseLike.html +2 -2
- package/typedoc/functions/shared_utils.isProxy.html +2 -2
- package/typedoc/functions/shared_utils.isRegExp.html +2 -2
- package/typedoc/functions/shared_utils.isScope.html +2 -2
- package/typedoc/functions/shared_utils.isString.html +2 -2
- package/typedoc/functions/shared_utils.isTypedArray.html +2 -2
- package/typedoc/functions/shared_utils.isUndefined.html +2 -2
- package/typedoc/functions/shared_utils.isValidObjectMaxDepth.html +2 -2
- package/typedoc/functions/shared_utils.isWindow.html +2 -2
- package/typedoc/functions/shared_utils.lowercase.html +2 -2
- package/typedoc/functions/shared_utils.mergeClasses.html +2 -2
- package/typedoc/functions/shared_utils.minErr.html +3 -3
- package/typedoc/functions/shared_utils.nextUid.html +2 -2
- package/typedoc/functions/shared_utils.parseKeyValue.html +2 -2
- package/typedoc/functions/shared_utils.replaceInline.html +2 -2
- package/typedoc/functions/shared_utils.setHashKey.html +2 -2
- package/typedoc/functions/shared_utils.shallowCopy.html +2 -2
- package/typedoc/functions/shared_utils.simpleCompare.html +2 -2
- package/typedoc/functions/shared_utils.sliceArgs.html +2 -2
- package/typedoc/functions/shared_utils.snakeCase.html +2 -2
- package/typedoc/functions/shared_utils.stringify.html +2 -2
- package/typedoc/functions/shared_utils.timezoneToOffset.html +2 -2
- package/typedoc/functions/shared_utils.toDebugString.html +2 -2
- package/typedoc/functions/shared_utils.toInt.html +2 -2
- package/typedoc/functions/shared_utils.toJson.html +3 -3
- package/typedoc/functions/shared_utils.toKeyValue.html +2 -2
- package/typedoc/functions/shared_utils.trim.html +2 -2
- package/typedoc/functions/shared_utils.tryDecodeURIComponent.html +2 -2
- package/typedoc/functions/shared_utils.uppercase.html +2 -2
- package/typedoc/hierarchy.html +3 -3
- package/typedoc/index.html +24 -24
- package/typedoc/interfaces/animations_animate.AnimationOptions.html +10 -10
- package/typedoc/interfaces/{types.OnChangesObject.html → animations_raf-scheduler.ServiceProvider.html} +38 -35
- package/typedoc/interfaces/core_cache_cache.ExpandoStore.html +8 -8
- package/typedoc/interfaces/core_compile_compile.LinkFnMapping.html +24 -24
- package/typedoc/interfaces/core_compile_compile.NodeLinkFnCtx.html +676 -0
- package/typedoc/interfaces/core_compile_compile.SimpleChange.html +6 -6
- package/typedoc/interfaces/core_location_location.DefaultPorts.html +8 -8
- package/typedoc/interfaces/core_location_location.Html5Mode.html +8 -8
- package/typedoc/interfaces/core_parse_ast_ast.Token.html +14 -14
- package/typedoc/interfaces/{core_parse_parse.CompiledExpressionHandlerMap.html → core_parse_interface.CompiledExpressionHandlerMap.html} +30 -14
- package/typedoc/interfaces/{core_parse_parse.CompiledExpressionProps.html → core_parse_interface.CompiledExpressionProps.html} +204 -50
- package/typedoc/interfaces/core_parse_lexer_lexer.LexerOptions.html +6 -6
- package/typedoc/interfaces/core_parse_parser_parser.ParsedAST.html +4 -4
- package/typedoc/interfaces/core_sanitize_interface.SanitizerFn.html +319 -0
- package/typedoc/interfaces/core_scope_scope.AsyncQueueTask.html +8 -8
- package/typedoc/interfaces/core_scope_scope.Listener.html +20 -20
- package/typedoc/interfaces/directive_model-options_model-options.ModelOptionsConfig.html +12 -12
- package/typedoc/interfaces/{types.ChangesObject.html → interface.ChangesObject.html} +35 -71
- package/typedoc/interfaces/interface.ComponentOptions.html +803 -0
- package/typedoc/interfaces/{types.Controller.html → interface.Controller.html} +27 -58
- package/typedoc/interfaces/{types.Directive.html → interface.Directive.html} +200 -163
- package/typedoc/interfaces/{types.DirectivePrePost.html → interface.DirectivePrePost.html} +20 -19
- package/typedoc/interfaces/interface.NgModelController.html +1530 -0
- package/typedoc/interfaces/{types.NgModelOptions.html → interface.NgModelOptions.html} +44 -26
- package/typedoc/interfaces/interface.Provider.html +1136 -0
- package/typedoc/interfaces/interface.TranscludeFunctionObject.html +770 -0
- package/typedoc/interfaces/loader.AngularBootstrapConfig.html +4 -4
- package/typedoc/interfaces/router_params_interface.ParamDeclaration.html +1324 -0
- package/typedoc/interfaces/router_params_interface.ParamTypeDefinition.html +1375 -0
- package/typedoc/{types/animations_raf-scheduler.RafSchedulerFunction.html → interfaces/router_params_interface.RawParams.html} +56 -13
- package/typedoc/interfaces/router_params_interface.Replace.html +465 -0
- package/typedoc/interfaces/router_resolve_interface.CustomAsyncPolicy.html +305 -0
- package/typedoc/interfaces/router_resolve_interface.ProviderLike.html +660 -0
- package/typedoc/interfaces/router_resolve_interface.ResolvableLiteral.html +670 -0
- package/typedoc/interfaces/router_resolve_interface.ResolvePolicy.html +674 -0
- package/typedoc/interfaces/router_state_interface.HrefOptions.html +588 -0
- package/typedoc/interfaces/{types.Annotated.html → router_state_interface.LazyLoadResult.html} +45 -24
- package/typedoc/interfaces/router_state_interface.StateDeclaration.html +2662 -0
- package/typedoc/interfaces/router_state_interface.TargetStateDef.html +515 -0
- package/typedoc/interfaces/router_state_interface.TransitionPromise.html +1241 -0
- package/typedoc/interfaces/router_state_interface.ViewDeclaration.html +1678 -0
- package/typedoc/interfaces/router_template-factory.BindingTuple.html +6 -6
- package/typedoc/interfaces/router_transition_interface.HookMatchCriteria.html +788 -0
- package/typedoc/interfaces/router_transition_interface.HookRegOptions.html +529 -0
- package/typedoc/interfaces/router_transition_interface.IHookRegistry.html +3093 -0
- package/typedoc/interfaces/router_transition_interface.IMatchingNodes.html +663 -0
- package/typedoc/interfaces/{animations_raf-scheduler.RafSchedulerObject.html → router_transition_interface.PathType.html} +76 -28
- package/typedoc/interfaces/{types.TranscludeFunctionObject.html → router_transition_interface.PathTypes.html} +199 -164
- package/typedoc/{types/core_parse_parse.CompiledExpressionFunction.html → interfaces/router_transition_interface.RegisteredHooks.html} +28 -14
- package/typedoc/interfaces/router_transition_interface.TransitionCreateHookFn.html +330 -0
- package/typedoc/interfaces/router_transition_interface.TransitionHookFn.html +366 -0
- package/typedoc/interfaces/router_transition_interface.TransitionHookOptions.html +718 -0
- package/typedoc/interfaces/router_transition_interface.TransitionOptions.html +1231 -0
- package/typedoc/interfaces/router_transition_interface.TransitionStateHookFn.html +388 -0
- package/typedoc/interfaces/router_transition_interface.TreeChanges.html +849 -0
- package/typedoc/interfaces/router_view_interface.ActiveUIView.html +700 -0
- package/typedoc/{classes/router_globals.UIRouterGlobals.html → interfaces/router_view_interface.ViewConfig.html} +235 -226
- package/typedoc/interfaces/router_view_interface.ViewContext.html +455 -0
- package/typedoc/interfaces/services_anchor-scroll.AnchorScrollObject.html +4 -4
- package/typedoc/interfaces/services_log.LogService.html +14 -14
- package/typedoc/{types/types.Injectable.html → interfaces/shared_interface.TypedMap.html} +24 -22
- package/typedoc/interfaces/shared_utils.ErrorHandlingConfig.html +6 -6
- package/typedoc/media/CONTRIBUTING.md +9 -9
- package/typedoc/media/DEVELOPERS.md +30 -30
- package/typedoc/modules/animations_interface.html +325 -0
- package/typedoc/modules/animations_raf-scheduler.html +15 -45
- package/typedoc/modules/core_compile_compile.html +27 -0
- package/typedoc/modules/core_error-handler.html +325 -0
- package/typedoc/modules/core_exception-handler.html +48 -12
- package/typedoc/modules/core_parse_ast_ast.html +0 -62
- package/typedoc/modules/core_parse_interface.html +473 -0
- package/typedoc/modules/core_parse_parse.html +0 -213
- package/typedoc/modules/core_sanitize_interface.html +323 -0
- package/typedoc/modules/core_sanitize_sanitize-uri.html +64 -0
- package/typedoc/modules/core_sce_sce.html +1 -1
- package/typedoc/modules/{types.html → interface.html} +106 -414
- package/typedoc/modules/router_common_glob.html +62 -181
- package/typedoc/modules/router_common_trace.html +65 -27
- package/typedoc/modules/router_globals.html +70 -6
- package/typedoc/modules/router_params_interface.html +405 -0
- package/typedoc/modules/router_resolve_interface.html +524 -0
- package/typedoc/modules/router_state_interface.html +609 -0
- package/typedoc/modules/router_state_state-object.html +64 -0
- package/typedoc/modules/router_state_state-registry.html +64 -0
- package/typedoc/modules/router_state_views.html +12 -14
- package/typedoc/modules/router_transition_interface.html +553 -14
- package/typedoc/modules/router_transition_transition.html +64 -0
- package/typedoc/modules/router_view_interface.html +376 -0
- package/typedoc/modules/shared_interface.html +439 -0
- package/typedoc/modules/shared_utils.html +26 -26
- package/typedoc/modules.html +267 -23
- package/typedoc/types/animations_animate.AnimationMethod.html +2 -2
- package/typedoc/types/animations_interface.RafScheduler.html +638 -0
- package/typedoc/types/core_cache_cache-factory.TemplateCache.html +2 -2
- package/typedoc/types/core_compile_compile.ApplyDirectivesToNodeFn.html +2 -2
- package/typedoc/types/core_compile_compile.BoundTranscludeFn.html +2 -2
- package/typedoc/types/core_compile_compile.CompileFn.html +2 -2
- package/typedoc/types/core_compile_compile.CompileNodesFn.html +2 -2
- package/typedoc/types/core_compile_compile.CompositeLinkFn.html +2 -2
- package/typedoc/types/core_compile_compile.NodeLinkFn.html +4 -34
- package/typedoc/types/core_compile_compile.PublicLinkFn.html +11 -2
- package/typedoc/types/core_compile_compile.TranscludeFn.html +2 -2
- package/typedoc/types/{core_exception-handler.ErrorHandler.html → core_error-handler.ErrorHandler.html} +8 -5
- package/typedoc/types/core_exception-handler.LogService.html +2 -2
- package/typedoc/types/core_parse_ast_ast-node.ASTNode.html +52 -52
- package/typedoc/types/{core_parse_parse.CompiledExpression.html → core_parse_interface.CompiledExpression.html} +13 -5
- package/typedoc/types/core_parse_interface.CompiledExpressionFunction.html +360 -0
- package/typedoc/types/core_parse_interface.ParseService.html +487 -0
- package/typedoc/types/core_parse_interpreter.DecoratedASTNode.html +2 -2
- package/typedoc/types/core_scope_scope.ListenerFunction.html +2 -2
- package/typedoc/types/core_url-utils_url-utils.HttpProtocol.html +2 -2
- package/typedoc/types/interface.AnnotatedFactory.html +288 -0
- package/typedoc/types/{types.CloneAttachFunction.html → interface.CloneAttachFunction.html} +6 -11
- package/typedoc/types/interface.ControllerConstructor.html +329 -0
- package/typedoc/types/interface.DirectiveCompileFn.html +420 -0
- package/typedoc/types/{types.DirectiveController.html → interface.DirectiveController.html} +9 -6
- package/typedoc/types/{types.DirectiveFactory.html → interface.DirectiveFactory.html} +12 -9
- package/typedoc/types/{types.DirectiveLinkFn.html → interface.DirectiveLinkFn.html} +60 -52
- package/typedoc/types/{types.Expression.html → interface.Expression.html} +14 -3
- package/typedoc/types/interface.FilterFactory.html +324 -0
- package/typedoc/types/interface.FilterFn.html +328 -0
- package/typedoc/types/{types.TAttributes.html → interface.Injectable.html} +15 -10
- package/typedoc/types/interface.InjectableFactory.html +323 -0
- package/typedoc/types/{types.Attributes.html → interface.OnChangesObject.html} +15 -9
- package/typedoc/types/{types.TController.html → interface.TController.html} +8 -5
- package/typedoc/types/{types.AnnotatedFunction.html → router_resolve_interface.PolicyAsync.html} +17 -15
- package/typedoc/types/{types.ServiceProvider.html → router_resolve_interface.PolicyWhen.html} +13 -10
- package/typedoc/{variables/router_transition_interface.TransitionHookScope.html → types/router_state_interface.RedirectToResult.html} +40 -38
- package/typedoc/types/router_state_interface.ResolveTypes.html +281 -0
- package/typedoc/types/{animations_raf-scheduler.RafScheduler.html → router_state_interface.StateOrName.html} +16 -15
- package/typedoc/types/router_state_interface._StateDeclaration.html +288 -0
- package/typedoc/types/router_transition_interface.HookFn.html +281 -0
- package/typedoc/{variables/router_common_trace.Category.html → types/router_transition_interface.HookMatchCriterion.html} +23 -19
- package/typedoc/types/router_transition_interface.HookResult.html +324 -0
- package/typedoc/types/{types.DirectiveCompileFn.html → router_transition_interface.IHookRegistration.html} +53 -53
- package/typedoc/{variables/core_parse_ast_ast.literals.html → types/router_transition_interface.IStateMatch.html} +27 -13
- package/typedoc/types/services_anchor-scroll.AnchorScrollFunction.html +2 -2
- package/typedoc/types/services_anchor-scroll.AnchorScrollService.html +2 -2
- package/typedoc/types/services_browser.UrlChangeListener.html +2 -2
- package/typedoc/types/services_log.LogCall.html +2 -2
- package/typedoc/types/shared_interface.Mapper.html +351 -0
- package/typedoc/types/shared_interface.Predicate.html +319 -0
- package/typedoc/types/shared_interface.PredicateBinary.html +344 -0
- package/typedoc/variables/animations_shared.ACTIVE_CLASS_SUFFIX.html +2 -2
- package/typedoc/variables/animations_shared.ADD_CLASS_SUFFIX.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATIONEND_EVENT.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATION_DELAY_PROP.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATION_DURATION_PROP.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATION_ITERATION_COUNT_KEY.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATION_PLAYSTATE_KEY.html +2 -2
- package/typedoc/variables/animations_shared.ANIMATION_PROP.html +2 -2
- package/typedoc/variables/animations_shared.CSS_PREFIX.html +2 -2
- package/typedoc/variables/animations_shared.DELAY_KEY.html +2 -2
- package/typedoc/variables/animations_shared.DURATION_KEY.html +2 -2
- package/typedoc/variables/animations_shared.EVENT_CLASS_PREFIX.html +2 -2
- package/typedoc/variables/animations_shared.NG_ANIMATE_CHILDREN_DATA.html +2 -2
- package/typedoc/variables/animations_shared.NG_ANIMATE_CLASSNAME.html +2 -2
- package/typedoc/variables/animations_shared.PREPARE_CLASS_SUFFIX.html +2 -2
- package/typedoc/variables/animations_shared.PROPERTY_KEY.html +2 -2
- package/typedoc/variables/animations_shared.REMOVE_CLASS_SUFFIX.html +2 -2
- package/typedoc/variables/animations_shared.SAFE_FAST_FORWARD_DURATION_VALUE.html +2 -2
- package/typedoc/variables/animations_shared.TIMING_KEY.html +2 -2
- package/typedoc/variables/animations_shared.TRANSITIONEND_EVENT.html +2 -2
- package/typedoc/variables/animations_shared.TRANSITION_DELAY_PROP.html +2 -2
- package/typedoc/variables/animations_shared.TRANSITION_DURATION_PROP.html +2 -2
- package/typedoc/variables/animations_shared.TRANSITION_PROP.html +2 -2
- package/typedoc/variables/animations_shared.ngMinErr.html +2 -2
- package/typedoc/variables/core_cache_cache.Cache.html +2 -2
- package/typedoc/variables/core_cache_cache.EXPANDO.html +2 -2
- package/typedoc/variables/core_cache_cache.ISOLATE_SCOPE_KEY.html +2 -2
- package/typedoc/variables/core_cache_cache.SCOPE_KEY.html +2 -2
- package/typedoc/variables/core_compile_compile.DirectiveSuffix.html +2 -2
- package/typedoc/variables/core_di_injector.path.html +2 -2
- package/typedoc/variables/core_di_ng-module.ANIMATION_LITERAL.html +2 -2
- package/typedoc/variables/core_di_ng-module.COMPILE_LITERAL.html +2 -2
- package/typedoc/variables/core_di_ng-module.CONTROLLER_LITERAL.html +2 -2
- package/typedoc/variables/core_di_ng-module.FILTER_LITERAL.html +2 -2
- package/typedoc/variables/core_di_ng-module.INJECTOR_LITERAL.html +2 -2
- package/typedoc/variables/core_di_ng-module.PROVIDE_LITERAL.html +2 -2
- package/typedoc/variables/core_parse_interpreter.PURITY_ABSOLUTE.html +2 -2
- package/typedoc/variables/core_parse_interpreter.PURITY_RELATIVE.html +2 -2
- package/typedoc/variables/core_pubsub_pubsub.EventBus.html +2 -2
- package/typedoc/variables/core_sce_sce.SCE_CONTEXTS.html +2 -2
- package/typedoc/variables/core_scope_scope.NONSCOPE.html +2 -2
- package/typedoc/variables/core_scope_scope.__applyAsyncQueue.html +2 -2
- package/typedoc/variables/core_scope_scope._postUpdateQueue.html +2 -2
- package/typedoc/variables/directive_attrs_attrs.REGEX_STRING_REGEXP.html +2 -2
- package/typedoc/variables/directive_attrs_attrs.ngAttributeAliasDirectives.html +2 -2
- package/typedoc/variables/directive_class_class.ngClassDirective.html +5 -5
- package/typedoc/variables/directive_class_class.ngClassEvenDirective.html +5 -5
- package/typedoc/variables/directive_class_class.ngClassOddDirective.html +5 -5
- package/typedoc/variables/directive_events_events.ngEventDirectives.html +2 -2
- package/typedoc/variables/directive_form_form.PENDING_CLASS.html +2 -2
- package/typedoc/variables/directive_form_form.formDirective.html +2 -2
- package/typedoc/variables/directive_form_form.ngFormDirective.html +2 -2
- package/typedoc/variables/directive_form_form.nullFormCtrl.html +2 -2
- package/typedoc/variables/directive_input_input.EMAIL_REGEXP.html +2 -2
- package/typedoc/variables/directive_input_input.ISO_DATE_REGEXP.html +2 -2
- package/typedoc/variables/directive_input_input.URL_REGEXP.html +2 -2
- package/typedoc/variables/directive_input_input.VALIDITY_STATE_PROPERTY.html +2 -2
- package/typedoc/variables/directive_messages_messages.ngMessageDefaultDirective.html +2 -2
- package/typedoc/variables/directive_messages_messages.ngMessageDirective.html +2 -2
- package/typedoc/variables/directive_messages_messages.ngMessageExpDirective.html +2 -2
- package/typedoc/variables/directive_model-options_model-options.defaultModelOptions.html +2 -2
- package/typedoc/variables/directive_model_model.ngModelMinErr.html +2 -2
- package/typedoc/variables/directive_options_options.ngOptionsDirective.html +6 -6
- package/typedoc/variables/directive_transclude_transclude.ngTranscludeDirective.html +6 -6
- package/typedoc/variables/directive_validators_validators.maxlengthDirective.html +12 -12
- package/typedoc/variables/directive_validators_validators.minlengthDirective.html +4 -4
- package/typedoc/variables/directive_validators_validators.patternDirective.html +12 -12
- package/typedoc/variables/directive_validators_validators.requiredDirective.html +12 -12
- package/typedoc/variables/index.angular.html +2 -2
- package/typedoc/variables/public.VERSION.html +3 -7
- package/typedoc/variables/router_common_trace.trace.html +2 -2
- package/typedoc/variables/router_directives_view-directive.ngView.html +7 -7
- package/typedoc/variables/router_hooks_resolve.RESOLVE_HOOK_PRIORITY.html +2 -2
- package/typedoc/variables/router_params_param.DefType.html +2 -2
- package/typedoc/variables/router_resolve_resolvable.defaultResolvePolicy.html +2 -2
- package/typedoc/variables/router_resolve_resolve-context.resolvePolicies.html +2 -2
- package/typedoc/variables/router_transition_transition-service.defaultTransOpts.html +2 -2
- package/typedoc/variables/services_log.LogService.html +4 -4
- package/typedoc/variables/shared_common.assertMap.html +2 -2
- package/typedoc/variables/shared_common.assertPredicate.html +2 -2
- package/typedoc/variables/shared_common.pushTo.html +2 -2
- package/typedoc/variables/shared_common.removeFrom.html +2 -2
- package/typedoc/variables/shared_constants.ALIASED_ATTR.html +2 -2
- package/typedoc/variables/shared_constants.DIRTY_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.EMPTY_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.INVALID_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.NOT_EMPTY_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.PREFIX_REGEXP.html +2 -2
- package/typedoc/variables/shared_constants.PRISTINE_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.SPECIAL_CHARS_REGEXP.html +2 -2
- package/typedoc/variables/shared_constants.TOUCHED_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.UNTOUCHED_CLASS.html +2 -2
- package/typedoc/variables/shared_constants.VALID_CLASS.html +2 -2
- package/typedoc/variables/shared_dom.BOOLEAN_ATTR.html +2 -2
- package/typedoc/variables/shared_hof.propEq.html +2 -2
- package/typedoc/variables/shared_strings.hostRegex.html +2 -2
- package/typedoc/variables/shared_strings.splitEqual.html +2 -2
- package/typedoc/variables/shared_strings.splitHash.html +2 -2
- package/typedoc/variables/shared_strings.splitQuery.html +2 -2
- package/typedoc/variables/shared_utils.isProxySymbol.html +2 -2
- package/typedoc/variables/shared_utils.ngAttrPrefixes.html +2 -2
- package/@types/directive/change/change.d.ts +0 -4
- package/@types/types.d.ts +0 -595
- package/src/types.js +0 -427
- package/typedoc/interfaces/types.FormController.html +0 -1541
- package/typedoc/interfaces/types.Module.html +0 -1566
- package/typedoc/interfaces/types.NgModelController.html +0 -2088
- package/typedoc/types/core_parse_parse.ParseService.html +0 -266
- package/typedoc/types/types.AsyncModelValidators.html +0 -266
- package/typedoc/types/types.BootstrapConfig.html +0 -262
- package/typedoc/types/types.ComponentOptions.html +0 -262
- package/typedoc/types/types.ControllerConstructor.html +0 -262
- package/typedoc/types/types.FilterFactory.html +0 -262
- package/typedoc/types/types.FilterFunction.html +0 -262
- package/typedoc/types/types.ModelValidators.html +0 -266
- package/typedoc/types/types.ServiceProviderFactory.html +0 -262
- package/typedoc/types/types.TElement.html +0 -262
- package/typedoc/types/types.TScope.html +0 -266
- package/typedoc/types/types.TranscludeFunction.html +0 -262
- package/typedoc/types/types.transcludeWithScope.html +0 -262
- package/typedoc/types/types.transcludeWithoutScope.html +0 -262
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
- annotated with dependencies and is responsible for creating a filter function.
|
|
10
10
|
-
|
|
11
11
|
- <div class="alert alert-warning">
|
|
12
|
-
- **Note:** Filter names must be valid
|
|
12
|
+
- **Note:** Filter names must be valid AngularTS {@link expression} identifiers, such as `uppercase` or `orderBy`.
|
|
13
13
|
- Names with special characters, such as hyphens and dots, are not allowed. If you wish to namespace
|
|
14
14
|
- your filters, then you can use capitalization (`myappSubsectionFilterx`) or underscores
|
|
15
15
|
- (`myapp_subsection_filterx`).
|
|
@@ -64,8 +64,8 @@
|
|
|
64
64
|
|
|
65
65
|
-
|
|
66
66
|
-
|
|
67
|
-
- For more information about how
|
|
68
|
-
- {@link guide/filter Filters} in the
|
|
67
|
+
- For more information about how AngularTS filters work, and how to create your own filters, see
|
|
68
|
+
- {@link guide/filter Filters} in the AngularTS Developer Guide.
|
|
69
69
|
\*/
|
|
70
70
|
|
|
71
71
|
/\*\*
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
- @description
|
|
77
77
|
- Filters are used for formatting data displayed to the user.
|
|
78
78
|
-
|
|
79
|
-
- They can be used in view templates, controllers or services.
|
|
79
|
+
- They can be used in view templates, controllers or services. AngularTS comes
|
|
80
80
|
- with a collection of [built-in filters](api/ng/filter), but it is easy to
|
|
81
81
|
- define your own as well.
|
|
82
82
|
-
|
|
@@ -121,7 +121,7 @@
|
|
|
121
121
|
- the keys are the filter names and the values are the filter factories.
|
|
122
122
|
-
|
|
123
123
|
- <div class="alert alert-warning">
|
|
124
|
-
- **Note:** Filter names must be valid
|
|
124
|
+
- **Note:** Filter names must be valid AngularTS {@link expression} identifiers, such as `uppercase` or `orderBy`.
|
|
125
125
|
- Names with special characters, such as hyphens and dots, are not allowed. If you wish to namespace
|
|
126
126
|
- your filters, then you can use capitalization (`myappSubsectionFilterx`) or underscores
|
|
127
127
|
- (`myapp_subsection_filterx`).
|
|
@@ -32,9 +32,9 @@ function interr(text, err) {
|
|
|
32
32
|
* Used for configuring the interpolation markup. Defaults to `{{` and `}}`.
|
|
33
33
|
*
|
|
34
34
|
* <div class="alert alert-danger">
|
|
35
|
-
* This feature is sometimes used to mix different markup languages, e.g. to wrap an
|
|
35
|
+
* This feature is sometimes used to mix different markup languages, e.g. to wrap an AngularTS
|
|
36
36
|
* template within a Python Jinja template (or any other template language). Mixing templating
|
|
37
|
-
* languages is **very dangerous**. The embedding template language will not safely escape
|
|
37
|
+
* languages is **very dangerous**. The embedding template language will not safely escape AngularTS
|
|
38
38
|
* expressions, so any user-controlled values in the template will cause Cross Site Scripting (XSS)
|
|
39
39
|
* security bugs!
|
|
40
40
|
* </div>
|
|
@@ -57,7 +57,7 @@ export class InterpolateProvider {
|
|
|
57
57
|
"$sce",
|
|
58
58
|
/**
|
|
59
59
|
*
|
|
60
|
-
* @param {import("../parse/
|
|
60
|
+
* @param {import("../parse/interface.ts").ParseService} $parse
|
|
61
61
|
* @param {*} $sce
|
|
62
62
|
* @returns
|
|
63
63
|
*/
|
|
@@ -97,7 +97,7 @@ export class InterpolateProvider {
|
|
|
97
97
|
* ```js
|
|
98
98
|
* let $interpolate = ...; // injected
|
|
99
99
|
* let exp = $interpolate('Hello {{name | uppercase}}!');
|
|
100
|
-
* expect(exp({name:'
|
|
100
|
+
* expect(exp({name:'AngularTS'})).toEqual('Hello ANGULARJS!');
|
|
101
101
|
* ```
|
|
102
102
|
*
|
|
103
103
|
* `$interpolate` takes an optional fourth argument, `allOrNothing`. If `allOrNothing` is
|
|
@@ -115,8 +115,8 @@ export class InterpolateProvider {
|
|
|
115
115
|
* // "allOrNothing" mode
|
|
116
116
|
* exp = $interpolate('{{greeting}} {{name}}!', false, null, true);
|
|
117
117
|
* expect(exp(context)).toBeUndefined();
|
|
118
|
-
* context.name = '
|
|
119
|
-
* expect(exp(context)).toEqual('Hello
|
|
118
|
+
* context.name = 'AngularTS';
|
|
119
|
+
* expect(exp(context)).toEqual('Hello AngularTS!');
|
|
120
120
|
* ```
|
|
121
121
|
*
|
|
122
122
|
* `allOrNothing` is useful for interpolating URLs. `ngSrc` and `ngSrcset` use this behavior.
|
|
@@ -289,7 +289,7 @@ describe("$interpolate", () => {
|
|
|
289
289
|
|
|
290
290
|
// This test demonstrates that the web-server is responsible for escaping every single instance
|
|
291
291
|
// of interpolation start/end markers in an expression which they do not wish to evaluate,
|
|
292
|
-
// because
|
|
292
|
+
// because AngularTS will not protect them from being evaluated (due to the added compleity
|
|
293
293
|
// and maintenance burden of context-sensitive escaping)
|
|
294
294
|
it("should evaluate expressions between escaped start/end symbols", () => {
|
|
295
295
|
expect($interpolate("\\{\\{Hello, {{bar}}!\\}\\}")(obj)).toBe(
|
|
@@ -156,7 +156,7 @@ export class Location {
|
|
|
156
156
|
*
|
|
157
157
|
* Return host of current URL.
|
|
158
158
|
*
|
|
159
|
-
* Note: compared to the non-
|
|
159
|
+
* Note: compared to the non-AngularTS version `location.host` which returns `hostname:port`, this returns the `hostname` portion only.
|
|
160
160
|
*
|
|
161
161
|
*
|
|
162
162
|
* @return {string} host of current URL.
|
|
@@ -507,7 +507,7 @@ export class LocationHashbangUrl extends Location {
|
|
|
507
507
|
* * a.setAttribute('href', '/foo')
|
|
508
508
|
* * a.pathname === '/C:/foo' //true
|
|
509
509
|
*
|
|
510
|
-
* Inside of
|
|
510
|
+
* Inside of AngularTS, we're always using pathnames that
|
|
511
511
|
* do not include drive names for routing.
|
|
512
512
|
*/
|
|
513
513
|
function removeWindowsDriveName(path, url, base) {
|
|
@@ -747,7 +747,7 @@ export class LocationProvider {
|
|
|
747
747
|
!event.defaultPrevented
|
|
748
748
|
) {
|
|
749
749
|
if ($location.$$parseLinkUrl(absHref, relHref)) {
|
|
750
|
-
// We do a preventDefault for all urls that are part of the
|
|
750
|
+
// We do a preventDefault for all urls that are part of the AngularTS application,
|
|
751
751
|
// in html5mode and also without, so that we are able to abort navigation without
|
|
752
752
|
// getting double entries in the location history.
|
|
753
753
|
event.preventDefault();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isAssignable } from "../interpreter.js";
|
|
2
2
|
import { ASTType } from "../ast-type.js";
|
|
3
|
-
import { minErr } from "../../../shared/utils.js";
|
|
3
|
+
import { hasOwn, minErr } from "../../../shared/utils.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* @typedef {import("./ast-node.ts").ASTNode} ASTNode
|
|
@@ -269,7 +269,7 @@ export class AST {
|
|
|
269
269
|
} else if (this.expect("{")) {
|
|
270
270
|
primary = this.object();
|
|
271
271
|
} else if (
|
|
272
|
-
|
|
272
|
+
hasOwn(
|
|
273
273
|
this.selfReferential,
|
|
274
274
|
/** @type {import("../lexer/lexer.js").Token} */ (this.peek()).text,
|
|
275
275
|
)
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import type { DecoratedASTNode } from "./interpreter.js";
|
|
2
|
+
import type { Scope } from "../scope/scope.js";
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Describes metadata and behavior for a compiled AngularJS expression.
|
|
6
|
+
*/
|
|
7
|
+
export interface CompiledExpressionProps {
|
|
8
|
+
/** Indicates if the expression is a literal. */
|
|
9
|
+
literal: boolean;
|
|
10
|
+
/** Indicates if the expression is constant. */
|
|
11
|
+
constant: boolean;
|
|
12
|
+
/** Optional flag for pure expressions. */
|
|
13
|
+
isPure?: boolean;
|
|
14
|
+
/** Indicates if the expression should be evaluated only once. */
|
|
15
|
+
oneTime: boolean;
|
|
16
|
+
/** AST node decorated with metadata. */
|
|
17
|
+
decoratedNode: DecoratedASTNode;
|
|
18
|
+
/**
|
|
19
|
+
* Optional custom watch delegate function for the expression.
|
|
20
|
+
* @param scope - The current scope.
|
|
21
|
+
* @param listener - A listener function.
|
|
22
|
+
* @param equalityCheck - Whether to use deep equality.
|
|
23
|
+
* @param expression - The compiled expression or string.
|
|
24
|
+
*/
|
|
25
|
+
$$watchDelegate?: (
|
|
26
|
+
scope: Scope,
|
|
27
|
+
listener: Function,
|
|
28
|
+
equalityCheck: boolean,
|
|
29
|
+
expression: CompiledExpression | string | ((scope: Scope) => any),
|
|
30
|
+
) => any;
|
|
31
|
+
/** Expression inputs; may be an array or a function. */
|
|
32
|
+
inputs: any[] | Function;
|
|
33
|
+
/**
|
|
34
|
+
* Optional assign function for two-way binding.
|
|
35
|
+
* Assigns a value to a context.
|
|
36
|
+
* If value is not provided, may return the getter.
|
|
37
|
+
*/
|
|
38
|
+
assign?: (context: any, value: any) => any;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Expression function with context and optional locals/assign.
|
|
43
|
+
* Evaluates the compiled expression.
|
|
44
|
+
*/
|
|
45
|
+
export type CompiledExpressionFunction = (
|
|
46
|
+
context: Scope,
|
|
47
|
+
locals?: object,
|
|
48
|
+
assign?: any,
|
|
49
|
+
) => any;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* A compiled expression that is both a function and includes expression metadata.
|
|
53
|
+
*/
|
|
54
|
+
export type CompiledExpression = CompiledExpressionFunction &
|
|
55
|
+
CompiledExpressionProps;
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Map used for expressions that watch specific object keys.
|
|
59
|
+
*/
|
|
60
|
+
export interface CompiledExpressionHandlerMap {
|
|
61
|
+
/** Indicates if the expression is a literal. */
|
|
62
|
+
literal: boolean;
|
|
63
|
+
/** Indicates if the expression is constant. */
|
|
64
|
+
constant: boolean;
|
|
65
|
+
/** Optional flag for pure expressions. */
|
|
66
|
+
isPure?: boolean;
|
|
67
|
+
/** Indicates if the expression should be evaluated only once. */
|
|
68
|
+
oneTime: boolean;
|
|
69
|
+
/** A map of property keys to observe. */
|
|
70
|
+
keyMap: Map<string, Function>;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Parses a string or expression function into a compiled expression.
|
|
75
|
+
* @param expression - The input expression (string or function).
|
|
76
|
+
* @param interceptorFn - Optional value transformer.
|
|
77
|
+
* @param expensiveChecks - Whether to enable expensive change detection.
|
|
78
|
+
* @returns A compiled expression.
|
|
79
|
+
*/
|
|
80
|
+
export type ParseService = (
|
|
81
|
+
expression: CompiledExpression | string | ((scope: Scope) => any),
|
|
82
|
+
interceptorFn?: (value: any, scope: Scope, locals: any) => any,
|
|
83
|
+
expensiveChecks?: boolean,
|
|
84
|
+
) => CompiledExpression;
|
|
@@ -15,16 +15,16 @@ export class ASTInterpreter {
|
|
|
15
15
|
/**
|
|
16
16
|
* Compiles the AST into a function.
|
|
17
17
|
* @param {import("./ast/ast").ASTNode} ast - The AST to compile.
|
|
18
|
-
* @returns {import("./
|
|
18
|
+
* @returns {import("./interface.ts").CompiledExpression}
|
|
19
19
|
*/
|
|
20
20
|
compile(ast) {
|
|
21
21
|
let decoratedNode = findConstantAndWatchExpressions(ast, this.$filter);
|
|
22
22
|
/** @type {import("./ast/ast").ASTNode} */
|
|
23
23
|
let assignable;
|
|
24
|
-
/** @type {import("./
|
|
24
|
+
/** @type {import("./interface.ts").CompiledExpression} */
|
|
25
25
|
let assign;
|
|
26
26
|
if ((assignable = assignableAST(decoratedNode))) {
|
|
27
|
-
assign = /** @type {import("./
|
|
27
|
+
assign = /** @type {import("./interface.ts").CompiledExpression} */ (
|
|
28
28
|
this.recurse(assignable)
|
|
29
29
|
);
|
|
30
30
|
}
|
|
@@ -33,9 +33,10 @@ export class ASTInterpreter {
|
|
|
33
33
|
if (toWatch) {
|
|
34
34
|
inputs = [];
|
|
35
35
|
for (const [key, watch] of Object.entries(toWatch)) {
|
|
36
|
-
const input =
|
|
37
|
-
|
|
38
|
-
|
|
36
|
+
const input =
|
|
37
|
+
/** @type {import("./interface.ts").CompiledExpression} */ (
|
|
38
|
+
this.recurse(watch)
|
|
39
|
+
);
|
|
39
40
|
input.isPure = watch.isPure;
|
|
40
41
|
watch.input = input;
|
|
41
42
|
inputs.push(input);
|
|
@@ -47,7 +48,7 @@ export class ASTInterpreter {
|
|
|
47
48
|
expressions.push(this.recurse(expression.expression));
|
|
48
49
|
});
|
|
49
50
|
|
|
50
|
-
/** @type {import("./
|
|
51
|
+
/** @type {import("./interface.ts").CompiledExpression} */
|
|
51
52
|
const fn =
|
|
52
53
|
decoratedNode.body.length === 0
|
|
53
54
|
? () => {}
|
|
@@ -75,7 +76,7 @@ export class ASTInterpreter {
|
|
|
75
76
|
* @param {import("./ast/ast").ASTNode} ast - The AST node.
|
|
76
77
|
* @param {Object} [context] - The context.
|
|
77
78
|
* @param {boolean|1} [create] - The create flag.
|
|
78
|
-
* @returns {import("./
|
|
79
|
+
* @returns {import("./interface.ts").CompiledExpressionFunction} The recursive function.
|
|
79
80
|
*/
|
|
80
81
|
recurse(ast, context, create) {
|
|
81
82
|
let left;
|
|
@@ -97,11 +98,13 @@ export class ASTInterpreter {
|
|
|
97
98
|
right = this.recurse(ast.right);
|
|
98
99
|
return this[`binary${ast.operator}`](left, right, context);
|
|
99
100
|
case ASTType.ConditionalExpression:
|
|
100
|
-
return
|
|
101
|
-
this
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
101
|
+
return /** @type {import("./interface.ts").CompiledExpressionFunction} */ (
|
|
102
|
+
this["ternary?:"](
|
|
103
|
+
this.recurse(ast.test),
|
|
104
|
+
this.recurse(ast.alternate),
|
|
105
|
+
this.recurse(ast.consequent),
|
|
106
|
+
context,
|
|
107
|
+
)
|
|
105
108
|
);
|
|
106
109
|
case ASTType.Identifier:
|
|
107
110
|
return self.identifier(ast.name, context, create);
|
|
@@ -111,19 +114,21 @@ export class ASTInterpreter {
|
|
|
111
114
|
right = ast.property.name;
|
|
112
115
|
}
|
|
113
116
|
if (ast.computed) right = this.recurse(ast.property);
|
|
114
|
-
return
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
117
|
+
return /** @type {import("./interface.ts").CompiledExpressionFunction} */ (
|
|
118
|
+
ast.computed
|
|
119
|
+
? this.computedMember(
|
|
120
|
+
left,
|
|
121
|
+
/** @type {function } */ (right),
|
|
122
|
+
context,
|
|
123
|
+
create,
|
|
124
|
+
)
|
|
125
|
+
: this.nonComputedMember(
|
|
126
|
+
left,
|
|
127
|
+
/** @type {string } */ (right),
|
|
128
|
+
context,
|
|
129
|
+
create,
|
|
130
|
+
)
|
|
131
|
+
);
|
|
127
132
|
case ASTType.CallExpression:
|
|
128
133
|
args = [];
|
|
129
134
|
ast.arguments.forEach((expr) => {
|
|
@@ -505,7 +510,7 @@ export class ASTInterpreter {
|
|
|
505
510
|
* Returns the value of a literal.
|
|
506
511
|
* @param {*} value - The literal value.
|
|
507
512
|
* @param {Object} [context] - The context.
|
|
508
|
-
* @returns {
|
|
513
|
+
* @returns {import("./interface.ts").CompiledExpressionFunction} The function returning the literal value.
|
|
509
514
|
*/
|
|
510
515
|
value(value, context) {
|
|
511
516
|
return function () {
|
|
@@ -518,7 +523,7 @@ export class ASTInterpreter {
|
|
|
518
523
|
* @param {string} name - The identifier name.
|
|
519
524
|
* @param {Object} [context] - The context.
|
|
520
525
|
* @param {boolean|1} [create] - Whether to create the identifier if it does not exist.
|
|
521
|
-
* @returns {
|
|
526
|
+
* @returns {import("./interface.ts").CompiledExpressionFunction} The function returning the identifier value.
|
|
522
527
|
*/
|
|
523
528
|
identifier(name, context, create) {
|
|
524
529
|
return function (scope, locals) {
|
package/src/core/parse/parse.js
CHANGED
|
@@ -3,46 +3,6 @@ import { PURITY_RELATIVE } from "./interpreter.js";
|
|
|
3
3
|
import { Lexer } from "./lexer/lexer.js";
|
|
4
4
|
import { Parser } from "./parser/parser.js";
|
|
5
5
|
|
|
6
|
-
/**
|
|
7
|
-
* @typedef {Object} CompiledExpressionProps
|
|
8
|
-
* @property {boolean} literal - Indicates if the expression is a literal.
|
|
9
|
-
* @property {boolean} constant - Indicates if the expression is constant.
|
|
10
|
-
* @property {boolean} [isPure]
|
|
11
|
-
* @property {boolean} oneTime
|
|
12
|
-
* @property {import("./interpreter.js").DecoratedASTNode} decoratedNode
|
|
13
|
-
* @property {function(import('../scope/scope.js').Scope, Function, boolean, CompiledExpression, string | ((scope: import('../scope/scope.js').Scope) => any) | CompiledExpression): any} [$$watchDelegate]
|
|
14
|
-
* @property {any[]|Function} inputs
|
|
15
|
-
* @property {function(any, any): any} [assign] - Assigns a value to a context. If value is not provided,
|
|
16
|
-
*/
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* @typedef {Object} CompiledExpressionHandlerMap
|
|
20
|
-
* @property {boolean} literal - Indicates if the expression is a literal.
|
|
21
|
-
* @property {boolean} constant - Indicates if the expression is constant.
|
|
22
|
-
* @property {boolean} [isPure]
|
|
23
|
-
* @property {boolean} oneTime
|
|
24
|
-
* @property {Map<string, Function>} keyMap - property keys to observe
|
|
25
|
-
*/
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* @typedef {Function} CompiledExpressionFunction
|
|
29
|
-
* @param {import('../scope/scope.js').Scope} context - An object against which any expressions embedded in the strings are evaluated against (typically a scope object).
|
|
30
|
-
* @param {object} [locals] - local variables context object, useful for overriding values in `context`.
|
|
31
|
-
* @param {any} [assign]
|
|
32
|
-
* @returns {any}
|
|
33
|
-
* undefined is gonna be used since the implementation
|
|
34
|
-
* does not check the parameter. Let's force a value for consistency. If consumer
|
|
35
|
-
* wants to undefine it, pass the undefined value explicitly.
|
|
36
|
-
*/
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* @typedef {CompiledExpressionFunction & CompiledExpressionProps} CompiledExpression
|
|
40
|
-
*/
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* @typedef {function(CompiledExpression|string|function(import('../scope/scope.js').Scope):any, function(any, import('../scope/scope.js').Scope, any):any=, boolean=): CompiledExpression} ParseService
|
|
44
|
-
*/
|
|
45
|
-
|
|
46
6
|
export function ParseProvider() {
|
|
47
7
|
const cache = Object.create(null);
|
|
48
8
|
|
|
@@ -53,7 +13,7 @@ export function ParseProvider() {
|
|
|
53
13
|
var identContinue;
|
|
54
14
|
|
|
55
15
|
/**
|
|
56
|
-
* Allows defining the set of characters that are allowed in
|
|
16
|
+
* Allows defining the set of characters that are allowed in AngularTS expressions. The function
|
|
57
17
|
* `identifierStart` will get called to know if a given character is a valid character to be the
|
|
58
18
|
* first character for an identifier. The function `identifierContinue` will get called to know if
|
|
59
19
|
* a given character is a valid character to be a follow-up identifier character. The functions
|
|
@@ -83,7 +43,7 @@ export function ParseProvider() {
|
|
|
83
43
|
/**
|
|
84
44
|
*
|
|
85
45
|
* @param {(any) => any} $filter
|
|
86
|
-
* @returns {ParseService}
|
|
46
|
+
* @returns {import('./interface').ParseService}
|
|
87
47
|
*/
|
|
88
48
|
function ($filter) {
|
|
89
49
|
/** @type {import("./lexer/lexer.js").LexerOptions} */
|
|
@@ -128,7 +88,7 @@ export function ParseProvider() {
|
|
|
128
88
|
/**
|
|
129
89
|
* @param {Function} parsedExpression
|
|
130
90
|
* @param interceptorFn
|
|
131
|
-
* @returns {CompiledExpression|*}
|
|
91
|
+
* @returns {import('./interface').CompiledExpression|*}
|
|
132
92
|
*/
|
|
133
93
|
function addInterceptor(parsedExpression, interceptorFn) {
|
|
134
94
|
if (!interceptorFn) return parsedExpression;
|
|
@@ -231,8 +191,8 @@ export function constantWatchDelegate(
|
|
|
231
191
|
|
|
232
192
|
/**
|
|
233
193
|
*
|
|
234
|
-
* @param {CompiledExpression} parsedExpression
|
|
235
|
-
* @returns {CompiledExpression}
|
|
194
|
+
* @param {import('./interface.ts').CompiledExpression} parsedExpression
|
|
195
|
+
* @returns {import('./interface.ts').CompiledExpression}
|
|
236
196
|
*/
|
|
237
197
|
function addWatchDelegate(parsedExpression) {
|
|
238
198
|
if (parsedExpression.constant) {
|
|
@@ -249,7 +209,7 @@ function addWatchDelegate(parsedExpression) {
|
|
|
249
209
|
* @param {import('../scope/scope.js').Scope} scope
|
|
250
210
|
* @param {Function} listener
|
|
251
211
|
* @param {*} objectEquality
|
|
252
|
-
* @param {CompiledExpression} parsedExpression
|
|
212
|
+
* @param {import('./interface').CompiledExpression} parsedExpression
|
|
253
213
|
* @returns
|
|
254
214
|
*/
|
|
255
215
|
function inputsWatchDelegate(
|
|
@@ -276,9 +236,7 @@ function inputsWatchDelegate(
|
|
|
276
236
|
inputExpression.isPure,
|
|
277
237
|
)
|
|
278
238
|
) {
|
|
279
|
-
lastResult = parsedExpression($scope, undefined,
|
|
280
|
-
newInputValue,
|
|
281
|
-
]);
|
|
239
|
+
lastResult = parsedExpression($scope, undefined, [newInputValue]);
|
|
282
240
|
oldInputValueOf = newInputValue && getValueOf(newInputValue);
|
|
283
241
|
}
|
|
284
242
|
return lastResult;
|
|
@@ -315,12 +273,7 @@ function inputsWatchDelegate(
|
|
|
315
273
|
}
|
|
316
274
|
|
|
317
275
|
if (changed) {
|
|
318
|
-
lastResult = parsedExpression(
|
|
319
|
-
scope,
|
|
320
|
-
undefined,
|
|
321
|
-
undefined,
|
|
322
|
-
oldInputValues,
|
|
323
|
-
);
|
|
276
|
+
lastResult = parsedExpression(scope, undefined, oldInputValues);
|
|
324
277
|
}
|
|
325
278
|
|
|
326
279
|
return lastResult;
|
package/src/core/parse/parse.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
// Sandboxing
|
|
1
|
+
// Sandboxing AngularTS Expressions
|
|
2
2
|
// ------------------------------
|
|
3
|
-
//
|
|
3
|
+
// AngularTS expressions are no longer sandboxed. So it is now even easier to access arbitrary JS code by
|
|
4
4
|
// various means such as obtaining a reference to native JS functions like the Function constructor.
|
|
5
5
|
//
|
|
6
|
-
// As an example, consider the following
|
|
6
|
+
// As an example, consider the following AngularTS expression:
|
|
7
7
|
//
|
|
8
8
|
// {}.toString.constructor('alert("evil JS code")')
|
|
9
9
|
//
|
|
@@ -20,14 +20,14 @@
|
|
|
20
20
|
-
|
|
21
21
|
- @description
|
|
22
22
|
-
|
|
23
|
-
- Converts
|
|
23
|
+
- Converts AngularTS {@link guide/expression expression} into a function.
|
|
24
24
|
-
|
|
25
25
|
- let getter = $parse('user.name');
|
|
26
26
|
- let setter = getter.assign;
|
|
27
|
-
- let context = {user:{name:'
|
|
27
|
+
- let context = {user:{name:'AngularTS'}};
|
|
28
28
|
- let locals = {user:{name:'local'}};
|
|
29
29
|
-
|
|
30
|
-
- expect(getter(context)).toEqual('
|
|
30
|
+
- expect(getter(context)).toEqual('AngularTS');
|
|
31
31
|
- setter(context, 'newValue');
|
|
32
32
|
- expect(context.user.name).toEqual('newValue');
|
|
33
33
|
- expect(getter(context, locals)).toEqual('local');
|
|
@@ -27,7 +27,7 @@ export class Parser {
|
|
|
27
27
|
/**
|
|
28
28
|
*
|
|
29
29
|
* @param {string} exp - Expression to be parsed
|
|
30
|
-
* @returns {import("../
|
|
30
|
+
* @returns {import("../interface.ts").CompiledExpression}
|
|
31
31
|
*/
|
|
32
32
|
parse(exp) {
|
|
33
33
|
const { ast } = this.getAst(exp);
|
|
@@ -1,84 +1,74 @@
|
|
|
1
1
|
import { isDefined } from "../../shared/utils.js";
|
|
2
2
|
import { urlResolve } from "../url-utils/url-utils.js";
|
|
3
3
|
|
|
4
|
+
/** @typedef {import('../../interface.ts').ServiceProvider} ServiceProvider } */
|
|
5
|
+
|
|
4
6
|
/**
|
|
5
|
-
*
|
|
6
|
-
* @description
|
|
7
7
|
* Private service to sanitize uris for links and images. Used by $compile.
|
|
8
|
+
* @implements {ServiceProvider}
|
|
8
9
|
*/
|
|
9
|
-
export
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
export class SanitizeUriProvider {
|
|
11
|
+
constructor() {
|
|
12
|
+
/**
|
|
13
|
+
* @private
|
|
14
|
+
* @type {RegExp}
|
|
15
|
+
*/
|
|
16
|
+
this._aHrefSanitizationTrustedUrlList =
|
|
17
|
+
/^\s*(https?|s?ftp|mailto|tel|file):/;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @private
|
|
21
|
+
* @type {RegExp}
|
|
22
|
+
*/
|
|
23
|
+
this._imgSrcSanitizationTrustedUrlList =
|
|
24
|
+
/^\s*((https?|ftp|file|blob):|data:image\/)/;
|
|
25
|
+
}
|
|
13
26
|
|
|
14
27
|
/**
|
|
15
|
-
*
|
|
16
|
-
* Retrieves or overrides the default regular expression that is used for determining trusted safe
|
|
17
|
-
* urls during a[href] sanitization.
|
|
18
|
-
*
|
|
19
|
-
* The sanitization is a security measure aimed at prevent XSS attacks via HTML anchor links.
|
|
20
|
-
*
|
|
21
|
-
* Any url due to be assigned to an `a[href]` attribute via interpolation is marked as requiring
|
|
22
|
-
* the $sce.URL security context. When interpolation occurs a call is made to `$sce.trustAsUrl(url)`
|
|
23
|
-
* which in turn may call `$$sanitizeUri(url, isMedia)` to sanitize the potentially malicious URL.
|
|
28
|
+
* Retrieves or overrides the regexp used to trust URLs for a[href] sanitization.
|
|
24
29
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* If there is no match the URL is returned prefixed with `'unsafe:'` to ensure that when it is written
|
|
28
|
-
* to the DOM it is inactive and potentially malicious code will not be executed.
|
|
29
|
-
*
|
|
30
|
-
* @param {RegExp=} regexp New regexp to trust urls with.
|
|
31
|
-
* @returns {RegExp|SanitizeUriProvider} Current RegExp if called without value or self for
|
|
32
|
-
* chaining otherwise.
|
|
30
|
+
* @param {RegExp=} regexp New regexp to trust URLs with.
|
|
31
|
+
* @returns {RegExp|SanitizeUriProvider} Current regexp if no param, or self for chaining.
|
|
33
32
|
*/
|
|
34
|
-
|
|
33
|
+
aHrefSanitizationTrustedUrlList(regexp) {
|
|
35
34
|
if (isDefined(regexp)) {
|
|
36
|
-
|
|
35
|
+
this._aHrefSanitizationTrustedUrlList = regexp;
|
|
37
36
|
return this;
|
|
38
37
|
}
|
|
39
|
-
return
|
|
40
|
-
}
|
|
38
|
+
return this._aHrefSanitizationTrustedUrlList;
|
|
39
|
+
}
|
|
41
40
|
|
|
42
41
|
/**
|
|
43
|
-
*
|
|
44
|
-
* Retrieves or overrides the default regular expression that is used for determining trusted safe
|
|
45
|
-
* urls during img[src] sanitization.
|
|
46
|
-
*
|
|
47
|
-
* The sanitization is a security measure aimed at prevent XSS attacks via HTML image src links.
|
|
48
|
-
*
|
|
49
|
-
* Any URL due to be assigned to an `img[src]` attribute via interpolation is marked as requiring
|
|
50
|
-
* the $sce.MEDIA_URL security context. When interpolation occurs a call is made to
|
|
51
|
-
* `$sce.trustAsMediaUrl(url)` which in turn may call `$$sanitizeUri(url, isMedia)` to sanitize
|
|
52
|
-
* the potentially malicious URL.
|
|
42
|
+
* Retrieves or overrides the regexp used to trust URLs for img[src] sanitization.
|
|
53
43
|
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* If there is no match the URL is returned prefixed with `'unsafe:'` to ensure that when it is written
|
|
58
|
-
* to the DOM it is inactive and potentially malicious code will not be executed.
|
|
59
|
-
*
|
|
60
|
-
* @param {RegExp=} regexp New regexp to trust urls with.
|
|
61
|
-
* @returns {RegExp|SanitizeUriProvider} Current RegExp if called without value or self for chaining otherwise.
|
|
44
|
+
* @param {RegExp=} regexp New regexp to trust URLs with.
|
|
45
|
+
* @returns {RegExp|SanitizeUriProvider} Current regexp if no param, or self for chaining.
|
|
62
46
|
*/
|
|
63
|
-
|
|
47
|
+
imgSrcSanitizationTrustedUrlList(regexp) {
|
|
64
48
|
if (isDefined(regexp)) {
|
|
65
|
-
|
|
49
|
+
this._imgSrcSanitizationTrustedUrlList = regexp;
|
|
66
50
|
return this;
|
|
67
51
|
}
|
|
68
|
-
return
|
|
69
|
-
}
|
|
52
|
+
return this._imgSrcSanitizationTrustedUrlList;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* @returns {import("./interface.js").SanitizerFn} Sanitizer function.
|
|
57
|
+
*/
|
|
58
|
+
$get() {
|
|
59
|
+
return (uri, isMediaUrl) => {
|
|
60
|
+
if (!uri) return uri;
|
|
70
61
|
|
|
71
|
-
this.$get = function () {
|
|
72
|
-
return function (uri, isMediaUrl) {
|
|
73
|
-
// if (!uri) return uri;
|
|
74
62
|
const regex = isMediaUrl
|
|
75
|
-
?
|
|
76
|
-
:
|
|
77
|
-
|
|
63
|
+
? this._imgSrcSanitizationTrustedUrlList
|
|
64
|
+
: this._aHrefSanitizationTrustedUrlList;
|
|
65
|
+
|
|
66
|
+
const normalizedVal = urlResolve(uri.trim()).href;
|
|
67
|
+
|
|
78
68
|
if (normalizedVal !== "" && !normalizedVal.match(regex)) {
|
|
79
69
|
return `unsafe:${normalizedVal}`;
|
|
80
70
|
}
|
|
81
71
|
return uri;
|
|
82
72
|
};
|
|
83
|
-
}
|
|
73
|
+
}
|
|
84
74
|
}
|