diff --git a/.circleci/config.yml b/.circleci/config.yml index dc492f19d19c..2a2130d6e838 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -28,18 +28,110 @@ executors: type: string default: medium docker: - - image: circleci/node:12.16.3@sha256:8fe514dae7585bbee1c64bf5a6cd4dcdf393316b5c87565b47e31014872c8860 + - image: circleci/node:14.16.1@sha256:b094e85848b43209ca83d9bb114d406fe62c75cb73b18c9d8eb1a9c6462c97d4 resource_class: << parameters.resource_class >> working_directory: ~/ng cloud-sdk: description: The docker container to use when running gcp-gcs commands docker: - image: google/cloud-sdk:alpine@sha256:7d0cae28cb282b76f2d9babe278c63c910d54f0cceca7a65fdf6806e2b43882e + working_directory: ~/ng + + +# Filter Definitions + +# Filter to run a job on all branches and any `v1.X.Y(-Z)` tags. +# Since the jobs need to run on tagged builds too, a `tags` section has to be explicitly specified. +# (The `branches` section could be omitted, since it defaults to all branches - just being explicit +# here). +# See also https://circleci.com/docs/2.0/workflows/#executing-workflows-for-a-git-tag. +var-filter-run-always: &run-always + filters: + branches: + only: /.*/ + tags: + only: /v1\.\d+\.\d.*/ + +# Filter to run a job when code might need to be deployed - i.e. on builds for the `master` branch. +# (Further checks are needed to determine whether a deployment is actually needed, but these are not +# possible via filters.) +var-filter-run-on-master: &run-on-master + filters: + branches: + only: + - master + tags: + ignore: /.*/ + +# Filter to run a job when code/docs might need to be deployed - i.e. on tagged builds and on builds +# for master and `v1.*.x` branches. +# (Further checks are needed to determine whether a deployment is actually needed, but these are not +# possible via filters.) +var-filter-run-on-tags-and-master-and-version-branches: &run-on-tags-and-master-and-version-branches + filters: + branches: + only: + - master + - /v1\.\d+\.x/ + tags: + only: /v1\.\d+\.\d.*/ + +# Filter to run a job when docs might need to be deployed - i.e. on builds for `v1.*.x` branches, +# which might correspond to the stable branch. +# (Further checks are needed to determine whether a deployment is actually needed, but these are not +# possible via filters.) +var-filter-run-on-version-branches: &run-on-version-branches + filters: + branches: + only: + - /v1\.\d+\.x/ + tags: + ignore: /.*/ # Command Definitions # https://circleci.com/docs/2.0/reusing-config/#authoring-reusable-commands commands: + skip_on_pr_and_fork_builds: + description: Skip a job on pull request and fork builds + steps: + - run: + name: Skip this job if this is a pull request or fork build + # Note: Using `CIRCLE_*` env variables (instead of those defined in `env.sh` so that this + # step can be run before `init_environment`. + command: > + if [[ -n "$CIRCLE_PR_NUMBER" ]] || + [[ "$CIRCLE_PROJECT_USERNAME" != "angular" ]] || + [[ "$CIRCLE_PROJECT_REPONAME" != "angular.js" ]]; then + echo "Skipping this job, because this is either a pull request or a fork build." + circleci step halt + fi + + skip_unless_stable_branch: + description: Skip a job unless this is the stable branch + steps: + - run: + name: Skip this job unless this is the stable branch + command: > + if [[ "$DIST_TAG" != "latest" ]]; then + echo "Skipping deployment, because this is not the stable branch." + circleci step halt + fi + + skip_unless_tag_or_master_or_stable_branch: + description: Skip a job unless this is a tag or the master or stable branch + steps: + - run: + name: Skip this job unless this is a tag or the master or stable branch + command: > + if [[ "$CI_GIT_TAG" == "false" ]] && + [[ "$CI_BRANCH" != "master" ]] && + [[ "$DIST_TAG" != "latest" ]]; then + echo "Skipping this job, because this is neither a tag nor the master or stable branch." + circleci step halt + fi + + custom_attach_workspace: description: Attach workspace at a predefined location steps: @@ -77,7 +169,6 @@ commands: echo 'github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==' >> ~/.ssh/known_hosts git config --global url."ssh://git@github.com".insteadOf "https://github.com" || true git config --global gc.auto 0 || true - - install_java init_saucelabs_environment: description: Sets up a domain that resolves to the local host. @@ -112,7 +203,6 @@ commands: name: Stopping Saucelabs tunnel service command: ./lib/saucelabs/sauce-service.sh stop - run_e2e_tests: parameters: specs: @@ -152,6 +242,7 @@ jobs: steps: - checkout - init_environment + - install_java - run: name: Running Yarn install command: yarn install --frozen-lockfile --non-interactive @@ -180,6 +271,7 @@ jobs: steps: - custom_attach_workspace - init_environment + - install_java - init_saucelabs_environment - run: yarn grunt test:promises-aplus - run: @@ -255,6 +347,7 @@ jobs: executor: name: default-executor steps: + - skip_on_pr_and_fork_builds - custom_attach_workspace - init_environment - run: yarn grunt prepareDeploy @@ -262,26 +355,23 @@ jobs: - persist_to_workspace: root: *workspace_location paths: - - ./ng/deploy - - deploy-docs: - executor: - name: default-executor - steps: - - custom_attach_workspace - - init_environment - - run: yarn grunt prepareDeploy - # Install dependencies for Firebase functions to prevent parsing errors during deployment - # See https://github.com/angular/angular.js/pull/16453 - - run: yarn -cwd ~/ng/scripts/docs.angularjs.org-firebase/functions - - run: yarn firebase deploy --token "$FIREBASE_TOKEN" --only hosting + - ./ng - deploy-code: + # The `deploy-code-files` job should only run when all of these conditions are true for the build: + # - It is for the `angular/angular.js` repository (not a fork). + # - It is not for a pull request. + # - It is for a tag or the master branch or the stable branch(*). + # + # *: The stable branch is the one that has the value `latest` in `package.json > distTag`. + deploy-code-files: executor: name: cloud-sdk steps: + - skip_on_pr_and_fork_builds - custom_attach_workspace - - run: ls ~/ng/deploy/code + - init_environment + - skip_unless_tag_or_master_or_stable_branch + - run: ls scripts/code.angularjs.org-firebase/deploy - run: name: Authenticate and configure Docker command: | @@ -290,48 +380,113 @@ jobs: - run: name: Sync files to code.angularjs.org command: | - gsutil -m rsync -r ~/ng/deploy/code gs://code-angularjs-org-338b8.appspot.com + gsutil -m rsync -r scripts/code.angularjs.org-firebase/deploy gs://code-angularjs-org-338b8.appspot.com + + # The `deploy-code-firebase` job should only run when all of these conditions are true for the build: + # - It is for the `angular/angular.js` repository (not a fork). + # - It is not for a pull request. + # - It is for the master branch. + # (This is enforced via job filters, so we don't need to a step to check it here.) + deploy-code-firebase: + executor: + name: default-executor + steps: + - skip_on_pr_and_fork_builds + - custom_attach_workspace + - init_environment + # Install dependencies for Firebase functions to prevent parsing errors during deployment. + # See https://github.com/angular/angular.js/pull/16453. + - run: + name: Install dependencies in `scripts/code.angularjs.org-firebase/functions/`. + working_directory: scripts/code.angularjs.org-firebase/functions + command: yarn install --frozen-lockfile --ignore-engines --non-interactive + - run: + name: Deploy to Firebase from `scripts/code.angularjs.org-firebase/`. + working_directory: scripts/code.angularjs.org-firebase + command: | + # Do not use `yarn firebase` as that causes the Firebase CLI to look for `firebase.json` + # in the root directory, even if run from inside `scripts/code.angularjs.org-firebase/`. + firebase=$(yarn bin)/firebase + $firebase use + $firebase deploy --message "Commit:\ $CI_COMMIT" --non-interactive --token "$FIREBASE_TOKEN" + + # The `deploy-docs` job should only run when all of these conditions are true for the build: + # - It is for the `angular/angular.js` repository (not a fork). + # - It is not for a pull request. + # - It is for the stable branch(*). + # + # *: The stable branch is the one that has the value `latest` in `package.json > distTag`. + deploy-docs: + executor: + name: default-executor + steps: + - skip_on_pr_and_fork_builds + - custom_attach_workspace + - init_environment + - skip_unless_stable_branch + # Install dependencies for Firebase functions to prevent parsing errors during deployment. + # See https://github.com/angular/angular.js/pull/16453. + - run: + name: Install dependencies in `scripts/docs.angularjs.org-firebase/functions/`. + working_directory: scripts/docs.angularjs.org-firebase/functions + command: yarn install --frozen-lockfile --ignore-engines --non-interactive + - run: + name: Deploy to Firebase from `scripts/docs.angularjs.org-firebase/`. + working_directory: scripts/docs.angularjs.org-firebase + command: | + # Do not use `yarn firebase` as that causes the Firebase CLI to look for `firebase.json` + # in the root directory, even if run from inside `scripts/docs.angularjs.org-firebase/`. + firebase=$(yarn bin)/firebase + $firebase use + $firebase deploy --message "Commit:\ $CI_COMMIT" --non-interactive --token "$FIREBASE_TOKEN" workflows: version: 2 default_workflow: jobs: - - setup + - setup: + <<: *run-always - lint: + <<: *run-always requires: - setup - unit-test: + <<: *run-always requires: - setup - unit-test-jquery: + <<: *run-always requires: - setup - e2e-test-1: + <<: *run-always requires: - setup - e2e-test-2a: + <<: *run-always requires: - setup - e2e-test-2b: + <<: *run-always requires: - setup - e2e-test-jquery-1: + <<: *run-always requires: - setup - e2e-test-jquery-2a: + <<: *run-always requires: - setup - e2e-test-jquery-2b: + <<: *run-always requires: - setup - prepare-deployment: - filters: - branches: - only: - - master - - latest + <<: *run-on-tags-and-master-and-version-branches requires: - setup + - lint - unit-test - unit-test-jquery - e2e-test-1 @@ -340,19 +495,15 @@ workflows: - e2e-test-jquery-1 - e2e-test-jquery-2a - e2e-test-jquery-2b - - - deploy-docs: - filters: - branches: - only: - - latest + - deploy-code-files: + <<: *run-on-tags-and-master-and-version-branches requires: - prepare-deployment - - deploy-code: - filters: - branches: - only: - - master - - latest + - deploy-code-firebase: + <<: *run-on-master + requires: + - prepare-deployment + - deploy-docs: + <<: *run-on-version-branches requires: - prepare-deployment diff --git a/.circleci/env.sh b/.circleci/env.sh index 72c047d58fec..338371017ccb 100755 --- a/.circleci/env.sh +++ b/.circleci/env.sh @@ -19,10 +19,9 @@ setPublicVar PROJECT_ROOT "$projectDir"; setPublicVar CI_BRANCH "$CIRCLE_BRANCH"; setPublicVar CI_BUILD_URL "$CIRCLE_BUILD_URL"; setPublicVar CI_COMMIT "$CIRCLE_SHA1"; -# `CI_COMMIT_RANGE` is only used on push builds (a.k.a. non-PR, non-scheduled builds and rerun -# workflows of such builds). setPublicVar CI_GIT_BASE_REVISION "${CIRCLE_GIT_BASE_REVISION}"; setPublicVar CI_GIT_REVISION "${CIRCLE_GIT_REVISION}"; +setPublicVar CI_GIT_TAG "${CIRCLE_TAG:-false}"; setPublicVar CI_COMMIT_RANGE "$CIRCLE_GIT_BASE_REVISION..$CIRCLE_GIT_REVISION"; setPublicVar CI_PULL_REQUEST "${CIRCLE_PR_NUMBER:-false}"; setPublicVar CI_REPO_NAME "$CIRCLE_PROJECT_REPONAME"; @@ -57,12 +56,14 @@ setPublicVar SAUCE_READY_FILE_TIMEOUT 120 #################################################################################################### # Define additional environment variables #################################################################################################### -setPublicVar DIST_TAG $( jq ".distTag" "package.json" | tr -d "\"[:space:]" ) + +# NOTE: Make sure the tools used to compute this are available in all executors in `config.yml`. +setPublicVar DIST_TAG $( cat package.json | grep distTag | sed -E 's/^\s*"distTag"\s*:\s*"([^"]+)"\s*,\s*$/\1/' ) #################################################################################################### #################################################################################################### ## Source `$BASH_ENV` to make the variables available immediately. ## -## ***NOTE: This must remain the the last action in this script*** ## +## *** NOTE: This must remain the last command in this script. *** ## #################################################################################################### #################################################################################################### source $BASH_ENV; diff --git a/.eslintrc-todo.json b/.eslintrc-todo.json index 7e89110084b7..a7b24d7a05b0 100644 --- a/.eslintrc-todo.json +++ b/.eslintrc-todo.json @@ -15,7 +15,7 @@ // Stylistic issues "block-spacing": ["error", "always"], "comma-spacing": "error", - "id-blacklist": ["error", "event"], + "id-denylist": ["error", "event"], "indent": ["error", 2], "key-spacing": ["error", { "beforeColon": false, "afterColon": true, "mode": "minimum" }], "object-curly-spacing": ["error", "never"], diff --git a/.gitignore b/.gitignore index 8226c42f29c4..9641ed4fd609 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,4 @@ /build/ -/deploy/ /benchpress-build/ .DS_Store gen_docs.disable @@ -23,5 +22,6 @@ npm-debug.log .vscode *.log *.stackdump +scripts/code.angularjs.org-firebase/deploy +scripts/docs.angularjs.org-firebase/deploy scripts/docs.angularjs.org-firebase/functions/content -/firebase.json diff --git a/.nvmrc b/.nvmrc index 48082f72f087..6b17d228d335 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -12 +14.16.1 diff --git a/CHANGELOG.md b/CHANGELOG.md index fcde4277c9f1..c720bd43ffa6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,54 @@ +**AngularJS support has officially ended as of January 2022. +[See what ending support means](https://docs.angularjs.org/misc/version-support-status) +and [read the end of life announcement](https://goo.gle/angularjs-end-of-life).** + +**Visit [angular.io](https://angular.io) for the actively supported Angular.** + + +# 1.8.3 ultimate-farewell (2022-04-07) + +One final release of AngularJS in order to update package README files on npm. + + +# 1.8.2 meteoric-mining (2020-10-21) + +## Bug Fixes +- **$sceDelegate:** ensure that `resourceUrlWhitelist()` is identical to `trustedResourceUrlList()` + ([e41f01](https://github.com/angular/angular.js/commit/e41f018959934bfbf982ba996cd654b1fce88d43), + [#17090](https://github.com/angular/angular.js/issues/17090)) + + + +# 1.8.1 mutually-supporting (2020-09-30) + +## Bug Fixes +- **$sanitize:** do not trigger CSP alert/report in Firefox and Chrome + ([2fab3d](https://github.com/angular/angular.js/commit/2fab3d4e00f4fe35bfa3cf255160cb97404baf24)) + +## Refactorings + +- **SanitizeUriProvider:** remove usages of whitelist + ([76738102](https://github.com/angular/angular.js/commit/767381020d88bda2855ac87ca6f00748907e14ff)) +- **httpProvider:** remove usages of whitelist and blacklist + ([c953af6b](https://github.com/angular/angular.js/commit/c953af6b8cfeefe4acc0ca358550eed5da8cfe00)) +- **sceDelegateProvider:** remove usages of whitelist and blacklist + ([a206e267](https://github.com/angular/angular.js/commit/a206e2675c351c3cdcde3402978126774c1c5df9)) + +## Deprecation Notices + +- Deprecated ~~`$compileProvider.aHrefSanitizationWhitelist`~~. + It is now [`aHrefSanitizationTrustedUrlList`](https://docs.angularjs.org/api/ng/provider/$compileProvider#aHrefSanitizationTrustedUrlList). +- Deprecated ~~`$compileProvider.imgSrcSanitizationWhitelist`~~. + It is now [`imgSrcSanitizationTrustedUrlList`](https://docs.angularjs.org/api/ng/provider/$compileProvider#imgSrcSanitizationTrustedUrlList). +- Deprecated ~~`$httpProvider.xsrfWhitelistedOrigins`~~. + It is now [`xsrfTrustedOrigins`](https://docs.angularjs.org/api/ng/provider/$httpProvider#xsrfTrustedOrigins). +- Deprecated ~~`$sceDelegateProvider.resourceUrlWhitelist`~~. + It is now [`trustedResourceUrlList`](https://docs.angularjs.org/api/ng/provider/$sceDelegateProvider#trustedResourceUrlList). +- Deprecated ~~`$sceDelegateProvider.resourceUrlBlacklist`~~. + It is now [`bannedResourceUrlList`](https://docs.angularjs.org/api/ng/provider/$sceDelegateProvider#bannedResourceUrlList). + +For the purposes of backward compatibility, the previous symbols are aliased to their new symbol. + # 1.8.0 nested-vaccination (2020-06-01) diff --git a/Gruntfile.js b/Gruntfile.js index fd52c82ce11a..4b647bb8f438 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -14,6 +14,7 @@ var semver = require('semver'); var exec = require('shelljs').exec; var pkg = require(__dirname + '/package.json'); +var codeScriptFolder = util.codeScriptFolder; var docsScriptFolder = util.docsScriptFolder; // Node.js version checks @@ -166,9 +167,9 @@ module.exports = function(grunt) { build: ['build'], tmp: ['tmp'], deploy: [ - 'deploy/docs', - 'deploy/code', - docsScriptFolder + '/functions/html' + codeScriptFolder + '/deploy', + docsScriptFolder + '/deploy', + docsScriptFolder + '/functions/content' ] }, @@ -372,7 +373,7 @@ module.exports = function(grunt) { { cwd: 'build', src: '**', - dest: 'deploy/code/' + deployVersion + '/', + dest: codeScriptFolder + '/deploy/' + deployVersion + '/', expand: true } ] @@ -382,19 +383,19 @@ module.exports = function(grunt) { // The source files are needed by the embedded examples in the docs app. { src: ['build/angular*.{js,js.map,min.js}', 'build/sitemap.xml'], - dest: 'deploy/docs/', + dest: docsScriptFolder + '/deploy/', expand: true, flatten: true }, { cwd: 'build/docs', src: ['**', '!ptore2e/**', '!index*.html'], - dest: 'deploy/docs/', + dest: docsScriptFolder + '/deploy/', expand: true }, { src: 'build/docs/index-production.html', - dest: 'deploy/docs/index.html' + dest: docsScriptFolder + '/deploy/index.html' }, { src: 'build/docs/index-production.html', @@ -403,7 +404,7 @@ module.exports = function(grunt) { { cwd: 'build/docs', src: 'partials/**', - dest: docsScriptFolder + '/functions/content', + dest: docsScriptFolder + '/functions/content/', expand: true } ] @@ -517,7 +518,6 @@ module.exports = function(grunt) { ]); grunt.registerTask('prepareDeploy', [ 'copy:deployFirebaseCode', - 'firebaseDocsJsonForCI', 'copy:deployFirebaseDocs' ]); grunt.registerTask('default', ['package']); diff --git a/LICENSE b/LICENSE index 0f2dbf8453d2..4ae0d5bb9fae 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ The MIT License -Copyright (c) 2010-2020 Google, Inc. http://angularjs.org +Copyright (c) 2010-2020 Google LLC. http://angularjs.org Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 3f03e5e79618..9a86e8b34858 100644 --- a/README.md +++ b/README.md @@ -14,9 +14,11 @@ piece of cake. Best of all? It makes development fun! -------------------- -**On July 1, 2018 AngularJS entered a 3 year Long Term Support period:** [Find out more](https://docs.angularjs.org/misc/version-support-status) +**AngularJS support has officially ended as of January 2022. +[See what ending support means](https://docs.angularjs.org/misc/version-support-status) +and [read the end of life announcement](https://goo.gle/angularjs-end-of-life).** -**Looking for the new Angular? Go here:** https://github.com/angular/angular +**Visit [angular.io](https://angular.io) for the actively supported Angular.** -------------------- @@ -55,11 +57,12 @@ component in an interconnected way like a well-oiled machine. AngularJS is JavaS and done right. (Well it is not really MVC, read on, to understand what this means.) #### MVC, no, MV* done the right way! -MVC, short for Model-View-Controller, is a design pattern, i.e. how the code should be organized and -how the different parts of an application separated for proper readability and debugging. Model is -the data and the database. View is the user interface and what the user sees. Controller is the main -link between Model and View. These are the three pillars of major programming frameworks present on -the market today. On the other hand AngularJS works on MV*, short for Model-View-_Whatever_. The +[MVC](https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93controller), short for +Model-View-Controller, is a design pattern, i.e. how the code should be organized and how the +different parts of an application separated for proper readability and debugging. Model is the data +and the database. View is the user interface and what the user sees. Controller is the main link +between Model and View. These are the three pillars of major programming frameworks present on the +market today. On the other hand AngularJS works on MV*, short for Model-View-_Whatever_. The _Whatever_ is AngularJS's way of telling that you may create any kind of linking between the Model and the View here. diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 000000000000..584eca530514 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,16 @@ +# Security Policy + +## Supported Versions + +**AngularJS support has officially ended as of January 2022.** +[See what ending support means](https://docs.angularjs.org/misc/version-support-status) +and [read the end of life announcement](https://goo.gle/angularjs-end-of-life). + +Visit [angular.io](https://angular.io) for the actively supported Angular. + +| Version | Supported | Status | Comments | +| ----------- | ------------------ | --------------------- | ------------------------------------ | +| 1.8.x | :x: | All support ended | | +| 1.3.x-1.7.x | :x: | All support ended | | +| 1.2.x | :x: | All support ended | Last version to provide IE 8 support | +| <1.2.0 | :x: | All support ended | | diff --git a/docs/app/assets/css/docs.css b/docs/app/assets/css/docs.css index 65abc5247f0c..eb28ad39d044 100644 --- a/docs/app/assets/css/docs.css +++ b/docs/app/assets/css/docs.css @@ -478,10 +478,10 @@ iframe.example { #navbar-sub { padding-top: 10px; padding-bottom: 5px; - background: rgba(245,245,245,0.88); + background: rgba(245,245,245,1); box-shadow: 0 0 2px #999; z-index: 1028; - top: 83px; + top: 57px; } .main-body-grid { @@ -982,7 +982,7 @@ toc-container > div > toc-tree > ul > li > toc-tree > ul > li toc-tree > ul li { #navbar-sub { position: relative; - top: 17px; + top: 0; margin-top: 80px; padding-bottom: 0; margin-bottom: 0; diff --git a/docs/app/src/examples.js b/docs/app/src/examples.js index b5b21c5393fa..7a5ebb62325f 100644 --- a/docs/app/src/examples.js +++ b/docs/app/src/examples.js @@ -55,7 +55,7 @@ angular.module('examples', []) return function(url, newWindow, fields) { /** * If the form posts to target="_blank", pop-up blockers can cause it not to work. - * If a user choses to bypass pop-up blocker one time and click the link, they will arrive at + * If a user chooses to bypass pop-up blocker one time and click the link, they will arrive at * a new default plnkr, not a plnkr with the desired template. Given this undesired behavior, * some may still want to open the plnk in a new window by opting-in via ctrl+click. The * newWindow param allows for this possibility. @@ -74,7 +74,7 @@ angular.module('examples', []) }]) .factory('createCopyrightNotice', function() { - var COPYRIGHT = 'Copyright ' + (new Date()).getFullYear() + ' Google Inc. All Rights Reserved.\n' + var COPYRIGHT = 'Copyright ' + (new Date()).getFullYear() + ' Google LLC. All Rights Reserved.\n' + 'Use of this source code is governed by an MIT-style license that\n' + 'can be found in the LICENSE file at http://angular.io/license'; var COPYRIGHT_JS_CSS = '\n\n/*\n' + COPYRIGHT + '\n*/'; diff --git a/docs/config/processors/keywords.js b/docs/config/processors/keywords.js index 8babc671dc5b..40fb97c63a89 100644 --- a/docs/config/processors/keywords.js +++ b/docs/config/processors/keywords.js @@ -47,13 +47,13 @@ module.exports = function generateKeywordsProcessor(log, readFilesProcessor) { } - areasToSearch = _.indexBy(this.areasToSearch); - propertiesToIgnore = _.indexBy(this.propertiesToIgnore); + areasToSearch = _.keyBy(this.areasToSearch); + propertiesToIgnore = _.keyBy(this.propertiesToIgnore); log.debug('Properties to ignore', propertiesToIgnore); - docTypesToIgnore = _.indexBy(this.docTypesToIgnore); + docTypesToIgnore = _.keyBy(this.docTypesToIgnore); log.debug('Doc types to ignore', docTypesToIgnore); - var ignoreWordsMap = _.indexBy(wordsToIgnore); + var ignoreWordsMap = _.keyBy(wordsToIgnore); // If the title contains a name starting with ng, e.g. "ngController", then add the module name // without the ng to the title text, e.g. "controller". diff --git a/docs/config/processors/pages-data.js b/docs/config/processors/pages-data.js index 9dc39b331257..c6e24bcb9568 100644 --- a/docs/config/processors/pages-data.js +++ b/docs/config/processors/pages-data.js @@ -224,7 +224,7 @@ module.exports = function generatePagesDataProcessor(log) { .map(function(doc) { return _.pick(doc, ['name', 'area', 'path']); }) - .indexBy('path') + .keyBy('path') .value(); docs.push({ diff --git a/docs/config/processors/versions-data.js b/docs/config/processors/versions-data.js index d52b6c420f69..fd7aceaa4d70 100644 --- a/docs/config/processors/versions-data.js +++ b/docs/config/processors/versions-data.js @@ -13,11 +13,11 @@ module.exports = function generateVersionDocProcessor(gitData) { return { $runAfter: ['generatePagesDataProcessor'], $runBefore: ['rendering-docs'], - // the blacklist is to remove rogue builds that are in the npm repository but not on code.angularjs.org - blacklist: ['1.3.4-build.3588'], + // Remove rogue builds that are in the npm repository but not on code.angularjs.org + ignoredBuilds: ['1.3.4-build.3588'], $process: function(docs) { - var blacklist = this.blacklist; + var ignoredBuilds = this.ignoredBuilds; var currentVersion = require('../../../build/version.json'); var output = exec('yarn info angular versions --json', { silent: true }).stdout.split('\n')[0]; var allVersions = processAllVersionsResponse(JSON.parse(output).data); @@ -57,7 +57,7 @@ module.exports = function generateVersionDocProcessor(gitData) { versions = versions .filter(function(versionStr) { - return blacklist.indexOf(versionStr) === -1; + return ignoredBuilds.indexOf(versionStr) === -1; }) .map(function(versionStr) { return semver.parse(versionStr); diff --git a/docs/config/templates/app/indexPage.template.html b/docs/config/templates/app/indexPage.template.html index 37c87ed112d8..126aab449e5e 100644 --- a/docs/config/templates/app/indexPage.template.html +++ b/docs/config/templates/app/indexPage.template.html @@ -142,21 +142,18 @@

{{ key }}

-