├── .env ├── .gitignore ├── .travis.yml ├── CHANGELOG.md ├── CONTRIBUTING.md ├── Gruntfile.js ├── Guardfile ├── LICENSE ├── Procfile ├── README.md ├── README.mdown ├── angularFiles.js ├── changelog.js ├── changelog.spec.js ├── changelog.tmp.md ├── check-size.sh ├── css ├── angular-scenario.css └── angular.css ├── docs ├── content │ ├── api │ │ ├── index.ngdoc │ │ └── ng.ngdoc │ ├── cookbook │ │ ├── advancedform.ngdoc │ │ ├── architecture.ngdoc │ │ ├── buzz.ngdoc │ │ ├── deeplinking.ngdoc │ │ ├── form.ngdoc │ │ ├── helloworld.ngdoc │ │ ├── index.ngdoc │ │ ├── jqplugins.ngdoc │ │ ├── module_value.ngdoc │ │ ├── mvc.ngdoc │ │ ├── service_provide_factory.ngdoc │ │ ├── toggle.ngdoc │ │ ├── tree.ngdoc │ │ └── watcharray.ngdoc │ ├── guide │ │ ├── bootstrap.ngdoc │ │ ├── compiler.ngdoc │ │ ├── concepts.ngdoc │ │ ├── dev_guide.e2e-testing.ngdoc │ │ ├── dev_guide.mvc.ngdoc │ │ ├── dev_guide.mvc.understanding_controller.ngdoc │ │ ├── dev_guide.mvc.understanding_model.ngdoc │ │ ├── dev_guide.mvc.understanding_view.ngdoc │ │ ├── dev_guide.services.$location.ngdoc │ │ ├── dev_guide.services.creating_services.ngdoc │ │ ├── dev_guide.services.injecting_controllers.ngdoc │ │ ├── dev_guide.services.managing_dependencies.ngdoc │ │ ├── dev_guide.services.ngdoc │ │ ├── dev_guide.services.testing_services.ngdoc │ │ ├── dev_guide.services.understanding_services.ngdoc │ │ ├── dev_guide.templates.css-styling.ngdoc │ │ ├── dev_guide.templates.databinding.ngdoc │ │ ├── dev_guide.templates.filters.creating_filters.ngdoc │ │ ├── dev_guide.templates.filters.ngdoc │ │ ├── dev_guide.templates.filters.using_filters.ngdoc │ │ ├── dev_guide.templates.ngdoc │ │ ├── dev_guide.unit-testing.ngdoc │ │ ├── di.ngdoc │ │ ├── directive.ngdoc │ │ ├── expression.ngdoc │ │ ├── forms.ngdoc │ │ ├── i18n.ngdoc │ │ ├── ie.ngdoc │ │ ├── index.ngdoc │ │ ├── introduction.ngdoc │ │ ├── module.ngdoc │ │ ├── overview.ngdoc │ │ ├── scope.ngdoc │ │ ├── type.ngdoc │ │ ├── understanding_directives.ngdoc │ │ └── understanding_scopes.ngdoc │ ├── misc │ │ ├── contribute.ngdoc │ │ ├── downloading.ngdoc │ │ ├── faq.ngdoc │ │ ├── started.ngdoc │ │ └── translate.ngdoc │ ├── tutorial │ │ ├── index.ngdoc │ │ ├── step_00.ngdoc │ │ ├── step_01.ngdoc │ │ ├── step_02.ngdoc │ │ ├── step_03.ngdoc │ │ ├── step_04.ngdoc │ │ ├── step_05.ngdoc │ │ ├── step_06.ngdoc │ │ ├── step_07.ngdoc │ │ ├── step_08.ngdoc │ │ ├── step_09.ngdoc │ │ ├── step_10.ngdoc │ │ ├── step_11.ngdoc │ │ └── the_end.ngdoc │ └── ui │ │ ├── api.ngdoc │ │ ├── compatibility.ngdoc │ │ ├── components.ngdoc │ │ ├── faq.ngdoc │ │ ├── index.ngdoc │ │ ├── multiple_views.ngdoc │ │ ├── nested_states.ngdoc │ │ ├── state_manager.ngdoc │ │ └── url_routing.ngdoc ├── img │ ├── AngularJS-small.png │ ├── One_Way_Data_Binding.png │ ├── Two_Way_Data_Binding.png │ ├── angular_parts.png │ ├── bullet.png │ ├── form_data_flow.png │ ├── glyphicons-halflings-white.png │ ├── glyphicons-halflings.png │ ├── guide │ │ ├── about_model_final.png │ │ ├── about_view_final.png │ │ ├── concepts-controller.png │ │ ├── concepts-directive.png │ │ ├── concepts-model.png │ │ ├── concepts-module-injector.png │ │ ├── concepts-runtime.png │ │ ├── concepts-scope.png │ │ ├── concepts-startup.png │ │ ├── concepts-view.png │ │ ├── di_sequence_final.png │ │ ├── dom_scope_final.png │ │ ├── hashbang_vs_regular_url.jpg │ │ ├── scenario_runner.png │ │ └── simple_scope_final.png │ ├── helloworld.png │ ├── helloworld_2way.png │ └── tutorial │ │ ├── catalog_screen.png │ │ ├── tutorial_00.png │ │ ├── tutorial_00_final.png │ │ ├── tutorial_02.png │ │ ├── tutorial_03.png │ │ ├── tutorial_04.png │ │ ├── tutorial_07_final.png │ │ ├── tutorial_08-09_final.png │ │ ├── tutorial_10-11_final.png │ │ └── xhr_service_final.png ├── spec │ ├── domSpec.js │ ├── ngdocSpec.js │ ├── sitemapSpec.js │ ├── specs.js │ └── writerSpec.js └── src │ ├── SiteMap.js │ ├── appCache.js │ ├── dom.js │ ├── example.js │ ├── gen-docs.js │ ├── ignore.words │ ├── ngdoc.js │ ├── reader.js │ ├── templates │ ├── .htaccess │ ├── css │ │ ├── animations.css │ │ ├── bootstrap.min.css │ │ ├── doc_widgets.css │ │ ├── docs.css │ │ └── font-awesome.css │ ├── docs-scenario.html │ ├── favicon.ico │ ├── font │ │ ├── fontawesome-webfont.eot │ │ ├── fontawesome-webfont.svg │ │ ├── fontawesome-webfont.svgz │ │ ├── fontawesome-webfont.ttf │ │ └── fontawesome-webfont.woff │ ├── home.html │ ├── index.html │ ├── js │ │ ├── docs.js │ │ ├── jquery.js │ │ └── jquery.min.js │ └── offline.html │ └── writer.js ├── example ├── buzz │ ├── buzz.css │ ├── buzz.html │ └── buzz.js ├── index.html ├── personalLog │ ├── personalLog.html │ ├── personalLog.js │ ├── scenario │ │ ├── personalLogScenario.js │ │ └── runner.html │ └── test │ │ └── personalLogSpec.js ├── temp.html ├── tweeter │ ├── style.css │ ├── tweeter_addressbook.html │ ├── tweeter_demo.html │ └── tweeterclient.js ├── view1.html └── view2.html ├── gdocs.js ├── gen_docs.sh ├── home ├── .htaccess ├── app.yaml ├── appcache.manifest ├── css │ ├── bootstrap-responsive.css │ ├── bootstrap-responsive.min.css │ ├── bootstrap.css │ ├── bootstrap.min.css │ ├── docs.css │ └── font-awesome.css ├── demos.py ├── favicon.ico ├── font │ ├── fontawesome-webfont.eot │ ├── fontawesome-webfont.svg │ ├── fontawesome-webfont.svgz │ ├── fontawesome-webfont.ttf │ └── fontawesome-webfont.woff ├── generatePassword.php ├── gitFetchSite.php ├── google-code-prettify │ ├── lang-apollo.js │ ├── lang-clj.js │ ├── lang-css.js │ ├── lang-go.js │ ├── lang-hs.js │ ├── lang-lisp.js │ ├── lang-lua.js │ ├── lang-ml.js │ ├── lang-n.js │ ├── lang-proto.js │ ├── lang-scala.js │ ├── lang-sql.js │ ├── lang-tex.js │ ├── lang-vb.js │ ├── lang-vhdl.js │ ├── lang-wiki.js │ ├── lang-xq.js │ ├── lang-yaml.js │ ├── prettify.css │ ├── prettify.js │ └── prettify.min.js ├── greet.php ├── img │ ├── AngularJS-large.png │ ├── AngularJS-small.png │ ├── glyphicons-halflings-white.png │ ├── glyphicons-halflings.png │ ├── google-black.png │ ├── google.png │ ├── video-over.png │ └── video.png ├── index.html ├── index.yaml ├── js │ ├── bootstrap.js │ ├── bootstrap.min.js │ └── homepage.js ├── misc │ ├── package.json │ └── resetProjects.js └── playswith.html ├── i18n ├── README.md ├── closure │ ├── currencySymbols.js │ ├── datetimeSymbolsExt.js │ ├── datetimesymbols.js │ ├── numberSymbols.js │ └── pluralRules.js ├── e2e │ ├── i18n-e2e.js │ ├── localeTest_cs.html │ ├── localeTest_de.html │ ├── localeTest_en.html │ ├── localeTest_es.html │ ├── localeTest_sk.html │ ├── localeTest_zh.html │ └── runner.html ├── generate.sh ├── run-tests.sh ├── spec │ ├── closureI18nExtractorSpec.js │ ├── converterSpec.js │ ├── parserSpec.js │ └── utilSpec.js ├── src │ ├── closureI18nExtractor.js │ ├── closureSlurper.js │ ├── converter.js │ ├── parser.js │ └── util.js └── update-closure.sh ├── images ├── css │ ├── arrow_left.gif │ ├── arrow_right.gif │ └── indicator-wait.png ├── docs │ ├── Diagrams.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ ├── image1.png │ │ ├── image2.png │ │ ├── image4.png │ │ ├── image8.png │ │ └── image9.png │ ├── guide │ │ ├── about_controller.graffle │ │ ├── about_model.graffle │ │ ├── about_view.graffle │ │ │ ├── QuickLook │ │ │ │ ├── Preview.pdf │ │ │ │ └── Thumbnail.tiff │ │ │ ├── data.plist │ │ │ └── image3.png │ │ ├── concepts.graffle │ │ │ ├── data.plist │ │ │ ├── image1.png │ │ │ ├── image4.png │ │ │ └── image5.png │ │ ├── di_sequence.graffle │ │ ├── dom_scope.graffle │ │ ├── form_data_flow.graffle │ │ ├── hashbang_vs_regular_url.graffle │ │ └── simple_scope.graffle │ │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ │ ├── data.plist │ │ │ └── image7.png │ └── tutorial │ │ ├── di_sequence.graffle │ │ ├── simple_scope.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image7.png │ │ ├── tutorial_00.graffle │ │ ├── tutorial_02.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image11.png │ │ ├── tutorial_03.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image13.png │ │ ├── tutorial_04.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image15.png │ │ ├── tutorial_07.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image9.png │ │ ├── tutorial_08-09.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image10.png │ │ ├── tutorial_10-11.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image10.png │ │ ├── tutorial_proto.graffle │ │ ├── QuickLook │ │ │ ├── Preview.pdf │ │ │ └── Thumbnail.tiff │ │ ├── data.plist │ │ └── image7.png │ │ └── xhr_service.graffle ├── favicon.ico └── logo │ ├── AngularJS-Shield.exports │ ├── AngularJS-Shield-huge.png │ ├── AngularJS-Shield-large.png │ ├── AngularJS-Shield-medium.png │ ├── AngularJS-Shield-small.png │ ├── AngularJS-Shield.eps │ └── AngularJS-Shield.pdf │ ├── AngularJS-Shield.graffle │ ├── AngularJS.exports │ ├── AngularJS-huge.png │ ├── AngularJS-large.png │ ├── AngularJS-medium.png │ ├── AngularJS-small.png │ ├── AngularJS.eps │ └── AngularJS.pdf │ └── AngularJS.graffle │ ├── data.plist │ ├── image1.png │ └── image2.png ├── init-app.sh ├── init-repo.sh ├── karma-e2e.conf.js ├── karma-jqlite.conf.js ├── karma-jquery.conf.js ├── karma-modules.conf.js ├── lib ├── closure-compiler │ ├── COPYING │ ├── README │ ├── compiler.jar │ └── version.txt ├── grunt │ ├── plugins.js │ └── utils.js ├── htmlparser │ └── htmlparser.js ├── jquery │ ├── jquery.js │ ├── jquery.min.js │ └── version.txt └── showdown │ ├── index.js │ └── showdown-0.9.js ├── logs ├── .gitignore └── .gitkeep ├── package.json ├── release-commit.sh ├── scripts ├── e2e-test.bat ├── e2e-test.sh ├── test.bat ├── test.sh ├── watchr.rb └── web-server.js ├── src ├── Angular.js ├── AngularPublic.js ├── angular-bootstrap.js ├── angular.prefix ├── angular.suffix ├── apis.js ├── auto │ └── injector.js ├── bootstrap │ ├── bootstrap-prettify.js │ ├── bootstrap.js │ ├── css │ │ └── bootstrap.css │ └── google-prettify │ │ ├── prettify.css │ │ └── prettify.js ├── jqLite.js ├── loader.js ├── loader.prefix ├── loader.suffix ├── module.prefix ├── module.suffix ├── ng │ ├── anchorScroll.js │ ├── animation.js │ ├── animator.js │ ├── browser.js │ ├── cacheFactory.js │ ├── compile.js │ ├── controller.js │ ├── directive │ │ ├── a.js │ │ ├── booleanAttrs.js │ │ ├── directives.js │ │ ├── form.js │ │ ├── input.js │ │ ├── ngBind.js │ │ ├── ngClass.js │ │ ├── ngCloak.js │ │ ├── ngController.js │ │ ├── ngCsp.js │ │ ├── ngEventDirs.js │ │ ├── ngIf.js │ │ ├── ngInclude.js │ │ ├── ngInit.js │ │ ├── ngNonBindable.js │ │ ├── ngPluralize.js │ │ ├── ngRepeat.js │ │ ├── ngShowHide.js │ │ ├── ngStyle.js │ │ ├── ngSwitch.js │ │ ├── ngTransclude.js │ │ ├── ngView.js │ │ ├── script.js │ │ ├── select.js │ │ └── style.js │ ├── document.js │ ├── exceptionHandler.js │ ├── filter.js │ ├── filter │ │ ├── filter.js │ │ ├── filters.js │ │ ├── limitTo.js │ │ └── orderBy.js │ ├── http.js │ ├── httpBackend.js │ ├── interpolate.js │ ├── locale.js │ ├── location.js │ ├── log.js │ ├── parse.js │ ├── q.js │ ├── rootElement.js │ ├── rootScope.js │ ├── route.js │ ├── routeParams.js │ ├── sniffer.js │ ├── timeout.js │ └── window.js ├── ngCookies │ └── cookies.js ├── ngLocale │ ├── angular-locale_af-na.js │ ├── angular-locale_af-za.js │ ├── angular-locale_af.js │ ├── angular-locale_am-et.js │ ├── angular-locale_am.js │ ├── angular-locale_ar-001.js │ ├── angular-locale_ar-ae.js │ ├── angular-locale_ar-bh.js │ ├── angular-locale_ar-dz.js │ ├── angular-locale_ar-eg.js │ ├── angular-locale_ar-iq.js │ ├── angular-locale_ar-jo.js │ ├── angular-locale_ar-kw.js │ ├── angular-locale_ar-lb.js │ ├── angular-locale_ar-ly.js │ ├── angular-locale_ar-ma.js │ ├── angular-locale_ar-om.js │ ├── angular-locale_ar-qa.js │ ├── angular-locale_ar-sa.js │ ├── angular-locale_ar-sd.js │ ├── angular-locale_ar-sy.js │ ├── angular-locale_ar-tn.js │ ├── angular-locale_ar-ye.js │ ├── angular-locale_ar.js │ ├── angular-locale_bg-bg.js │ ├── angular-locale_bg.js │ ├── angular-locale_bn-bd.js │ ├── angular-locale_bn-in.js │ ├── angular-locale_bn.js │ ├── angular-locale_ca-ad.js │ ├── angular-locale_ca-es.js │ ├── angular-locale_ca.js │ ├── angular-locale_chr.js │ ├── angular-locale_cs-cz.js │ ├── angular-locale_cs.js │ ├── angular-locale_cy.js │ ├── angular-locale_da-dk.js │ ├── angular-locale_da.js │ ├── angular-locale_de-at.js │ ├── angular-locale_de-be.js │ ├── angular-locale_de-ch.js │ ├── angular-locale_de-de.js │ ├── angular-locale_de-li.js │ ├── angular-locale_de-lu.js │ ├── angular-locale_de.js │ ├── angular-locale_el-cy.js │ ├── angular-locale_el-gr.js │ ├── angular-locale_el-polyton.js │ ├── angular-locale_el.js │ ├── angular-locale_en-as.js │ ├── angular-locale_en-au.js │ ├── angular-locale_en-bb.js │ ├── angular-locale_en-be.js │ ├── angular-locale_en-bm.js │ ├── angular-locale_en-bw.js │ ├── angular-locale_en-bz.js │ ├── angular-locale_en-ca.js │ ├── angular-locale_en-dsrt-us.js │ ├── angular-locale_en-dsrt.js │ ├── angular-locale_en-fm.js │ ├── angular-locale_en-gb.js │ ├── angular-locale_en-gu.js │ ├── angular-locale_en-gy.js │ ├── angular-locale_en-hk.js │ ├── angular-locale_en-ie.js │ ├── angular-locale_en-in.js │ ├── angular-locale_en-iso.js │ ├── angular-locale_en-jm.js │ ├── angular-locale_en-mh.js │ ├── angular-locale_en-mp.js │ ├── angular-locale_en-mt.js │ ├── angular-locale_en-mu.js │ ├── angular-locale_en-na.js │ ├── angular-locale_en-nz.js │ ├── angular-locale_en-ph.js │ ├── angular-locale_en-pk.js │ ├── angular-locale_en-pr.js │ ├── angular-locale_en-pw.js │ ├── angular-locale_en-sg.js │ ├── angular-locale_en-tc.js │ ├── angular-locale_en-tt.js │ ├── angular-locale_en-um.js │ ├── angular-locale_en-us.js │ ├── angular-locale_en-vg.js │ ├── angular-locale_en-vi.js │ ├── angular-locale_en-za.js │ ├── angular-locale_en-zw.js │ ├── angular-locale_en-zz.js │ ├── angular-locale_en.js │ ├── angular-locale_es-419.js │ ├── angular-locale_es-ar.js │ ├── angular-locale_es-bo.js │ ├── angular-locale_es-cl.js │ ├── angular-locale_es-co.js │ ├── angular-locale_es-cr.js │ ├── angular-locale_es-do.js │ ├── angular-locale_es-ea.js │ ├── angular-locale_es-ec.js │ ├── angular-locale_es-es.js │ ├── angular-locale_es-gq.js │ ├── angular-locale_es-gt.js │ ├── angular-locale_es-hn.js │ ├── angular-locale_es-ic.js │ ├── angular-locale_es-mx.js │ ├── angular-locale_es-ni.js │ ├── angular-locale_es-pa.js │ ├── angular-locale_es-pe.js │ ├── angular-locale_es-pr.js │ ├── angular-locale_es-py.js │ ├── angular-locale_es-sv.js │ ├── angular-locale_es-us.js │ ├── angular-locale_es-uy.js │ ├── angular-locale_es-ve.js │ ├── angular-locale_es.js │ ├── angular-locale_et-ee.js │ ├── angular-locale_et.js │ ├── angular-locale_eu-es.js │ ├── angular-locale_eu.js │ ├── angular-locale_fa-af.js │ ├── angular-locale_fa-ir.js │ ├── angular-locale_fa.js │ ├── angular-locale_fi-fi.js │ ├── angular-locale_fi.js │ ├── angular-locale_fil-ph.js │ ├── angular-locale_fil.js │ ├── angular-locale_fr-be.js │ ├── angular-locale_fr-bf.js │ ├── angular-locale_fr-bi.js │ ├── angular-locale_fr-bj.js │ ├── angular-locale_fr-bl.js │ ├── angular-locale_fr-ca.js │ ├── angular-locale_fr-cd.js │ ├── angular-locale_fr-cf.js │ ├── angular-locale_fr-cg.js │ ├── angular-locale_fr-ch.js │ ├── angular-locale_fr-ci.js │ ├── angular-locale_fr-cm.js │ ├── angular-locale_fr-dj.js │ ├── angular-locale_fr-fr.js │ ├── angular-locale_fr-ga.js │ ├── angular-locale_fr-gf.js │ ├── angular-locale_fr-gn.js │ ├── angular-locale_fr-gp.js │ ├── angular-locale_fr-gq.js │ ├── angular-locale_fr-km.js │ ├── angular-locale_fr-lu.js │ ├── angular-locale_fr-mc.js │ ├── angular-locale_fr-mf.js │ ├── angular-locale_fr-mg.js │ ├── angular-locale_fr-ml.js │ ├── angular-locale_fr-mq.js │ ├── angular-locale_fr-ne.js │ ├── angular-locale_fr-re.js │ ├── angular-locale_fr-rw.js │ ├── angular-locale_fr-sn.js │ ├── angular-locale_fr-td.js │ ├── angular-locale_fr-tg.js │ ├── angular-locale_fr-yt.js │ ├── angular-locale_fr.js │ ├── angular-locale_gl-es.js │ ├── angular-locale_gl.js │ ├── angular-locale_gsw-ch.js │ ├── angular-locale_gsw.js │ ├── angular-locale_gu-in.js │ ├── angular-locale_gu.js │ ├── angular-locale_haw.js │ ├── angular-locale_he-il.js │ ├── angular-locale_he.js │ ├── angular-locale_hi-in.js │ ├── angular-locale_hi.js │ ├── angular-locale_hr-hr.js │ ├── angular-locale_hr.js │ ├── angular-locale_hu-hu.js │ ├── angular-locale_hu.js │ ├── angular-locale_id-id.js │ ├── angular-locale_id.js │ ├── angular-locale_in.js │ ├── angular-locale_is-is.js │ ├── angular-locale_is.js │ ├── angular-locale_it-ch.js │ ├── angular-locale_it-it.js │ ├── angular-locale_it-sm.js │ ├── angular-locale_it.js │ ├── angular-locale_iw.js │ ├── angular-locale_ja-jp.js │ ├── angular-locale_ja.js │ ├── angular-locale_kn-in.js │ ├── angular-locale_kn.js │ ├── angular-locale_ko-kr.js │ ├── angular-locale_ko.js │ ├── angular-locale_ln-cd.js │ ├── angular-locale_ln-cg.js │ ├── angular-locale_ln.js │ ├── angular-locale_lt-lt.js │ ├── angular-locale_lt.js │ ├── angular-locale_lv-lv.js │ ├── angular-locale_lv.js │ ├── angular-locale_ml-in.js │ ├── angular-locale_ml.js │ ├── angular-locale_mo.js │ ├── angular-locale_mr-in.js │ ├── angular-locale_mr.js │ ├── angular-locale_ms-bn.js │ ├── angular-locale_ms-my.js │ ├── angular-locale_ms.js │ ├── angular-locale_mt-mt.js │ ├── angular-locale_mt.js │ ├── angular-locale_nl-aw.js │ ├── angular-locale_nl-be.js │ ├── angular-locale_nl-cw.js │ ├── angular-locale_nl-nl.js │ ├── angular-locale_nl-sx.js │ ├── angular-locale_nl.js │ ├── angular-locale_no.js │ ├── angular-locale_or-in.js │ ├── angular-locale_or.js │ ├── angular-locale_pl-pl.js │ ├── angular-locale_pl.js │ ├── angular-locale_pt-ao.js │ ├── angular-locale_pt-br.js │ ├── angular-locale_pt-gw.js │ ├── angular-locale_pt-mz.js │ ├── angular-locale_pt-pt.js │ ├── angular-locale_pt-st.js │ ├── angular-locale_pt.js │ ├── angular-locale_ro-md.js │ ├── angular-locale_ro-ro.js │ ├── angular-locale_ro.js │ ├── angular-locale_ru-md.js │ ├── angular-locale_ru-ru.js │ ├── angular-locale_ru-ua.js │ ├── angular-locale_ru.js │ ├── angular-locale_sk-sk.js │ ├── angular-locale_sk.js │ ├── angular-locale_sl-si.js │ ├── angular-locale_sl.js │ ├── angular-locale_sq-al.js │ ├── angular-locale_sq.js │ ├── angular-locale_sr-cyrl-ba.js │ ├── angular-locale_sr-cyrl-me.js │ ├── angular-locale_sr-cyrl-rs.js │ ├── angular-locale_sr-cyrl.js │ ├── angular-locale_sr-latn-ba.js │ ├── angular-locale_sr-latn-me.js │ ├── angular-locale_sr-latn-rs.js │ ├── angular-locale_sr-latn.js │ ├── angular-locale_sr-rs.js │ ├── angular-locale_sr.js │ ├── angular-locale_sv-fi.js │ ├── angular-locale_sv-se.js │ ├── angular-locale_sv.js │ ├── angular-locale_sw-ke.js │ ├── angular-locale_sw-tz.js │ ├── angular-locale_sw.js │ ├── angular-locale_ta-in.js │ ├── angular-locale_ta-lk.js │ ├── angular-locale_ta.js │ ├── angular-locale_te-in.js │ ├── angular-locale_te.js │ ├── angular-locale_th-th.js │ ├── angular-locale_th.js │ ├── angular-locale_tl-ph.js │ ├── angular-locale_tl.js │ ├── angular-locale_tr-tr.js │ ├── angular-locale_tr.js │ ├── angular-locale_uk-ua.js │ ├── angular-locale_uk.js │ ├── angular-locale_ur-in.js │ ├── angular-locale_ur-pk.js │ ├── angular-locale_ur.js │ ├── angular-locale_vi-vn.js │ ├── angular-locale_vi.js │ ├── angular-locale_zh-cn.js │ ├── angular-locale_zh-hans-cn.js │ ├── angular-locale_zh-hans-hk.js │ ├── angular-locale_zh-hans-mo.js │ ├── angular-locale_zh-hans-sg.js │ ├── angular-locale_zh-hans.js │ ├── angular-locale_zh-hant-hk.js │ ├── angular-locale_zh-hant-mo.js │ ├── angular-locale_zh-hant-tw.js │ ├── angular-locale_zh-hant.js │ ├── angular-locale_zh-hk.js │ ├── angular-locale_zh-tw.js │ ├── angular-locale_zh.js │ ├── angular-locale_zu-za.js │ └── angular-locale_zu.js ├── ngMobile │ ├── directive │ │ ├── ngClick.js │ │ └── ngSwipe.js │ └── mobile.js ├── ngMock │ └── angular-mocks.js ├── ngResource │ └── resource.js ├── ngSanitize │ ├── directive │ │ └── ngBindHtml.js │ ├── filter │ │ └── linky.js │ └── sanitize.js ├── ngScenario │ ├── Application.js │ ├── Describe.js │ ├── Future.js │ ├── ObjectModel.js │ ├── Runner.js │ ├── Scenario.js │ ├── SpecRunner.js │ ├── angular-bootstrap.js │ ├── angular.prefix │ ├── angular.suffix │ ├── browserTrigger.js │ ├── dsl.js │ ├── matchers.js │ └── output │ │ ├── Html.js │ │ ├── Json.js │ │ ├── Object.js │ │ └── Xml.js └── publishExternalApis.js ├── start-iteration.sh ├── test ├── AngularSpec.js ├── ApiSpecs.js ├── BinderSpec.js ├── auto │ └── injectorSpec.js ├── bootstrap │ ├── bootstrapSpec.js │ └── code.html ├── e2e │ ├── runner.html │ └── scenarios.js ├── jQueryPatchSpec.js ├── jqLiteSpec.js ├── jquery_alias.js ├── jquery_remove.js ├── lib │ └── angular │ │ ├── angular-mocks.js │ │ ├── angular-scenario.js │ │ └── version.txt ├── loaderSpec.js ├── matchers.js ├── ng │ ├── anchorScrollSpec.js │ ├── animationSpec.js │ ├── animatorSpec.js │ ├── browserSpecs.js │ ├── cacheFactorySpec.js │ ├── compileSpec.js │ ├── controllerSpec.js │ ├── directive │ │ ├── aSpec.js │ │ ├── booleanAttrsSpec.js │ │ ├── formSpec.js │ │ ├── inputSpec.js │ │ ├── ngBindSpec.js │ │ ├── ngClassSpec.js │ │ ├── ngClickSpec.js │ │ ├── ngCloakSpec.js │ │ ├── ngControllerSpec.js │ │ ├── ngCspSpec.js │ │ ├── ngEventDirsSpec.js │ │ ├── ngIfSpec.js │ │ ├── ngIncludeSpec.js │ │ ├── ngInitSpec.js │ │ ├── ngKeySpec.js │ │ ├── ngNonBindableSpec.js │ │ ├── ngPluralizeSpec.js │ │ ├── ngRepeatSpec.js │ │ ├── ngShowHideSpec.js │ │ ├── ngSrcSpec.js │ │ ├── ngStyleSpec.js │ │ ├── ngSwitchSpec.js │ │ ├── ngViewSpec.js │ │ ├── scriptSpec.js │ │ ├── selectSpec.js │ │ └── styleSpec.js │ ├── documentSpec.js │ ├── exceptionHandlerSpec.js │ ├── filter │ │ ├── filterSpec.js │ │ ├── filtersSpec.js │ │ ├── limitToSpec.js │ │ └── orderBySpec.js │ ├── httpBackendSpec.js │ ├── httpSpec.js │ ├── interpolateSpec.js │ ├── localeSpec.js │ ├── locationSpec.js │ ├── logSpec.js │ ├── parseSpec.js │ ├── qSpec.js │ ├── rootElementSpec.js │ ├── rootScopeSpec.js │ ├── routeParamsSpec.js │ ├── routeSpec.js │ ├── snifferSpec.js │ ├── timeoutSpec.js │ └── windowSpec.js ├── ngCookies │ └── cookiesSpec.js ├── ngMobile │ └── directive │ │ ├── ngClickSpec.js │ │ └── ngSwipeSpec.js ├── ngMock │ └── angular-mocksSpec.js ├── ngResource │ └── resourceSpec.js ├── ngSanitize │ ├── directive │ │ └── ngBindHtmlSpec.js │ ├── filter │ │ └── linkySpec.js │ └── sanitizeSpec.js ├── ngScenario │ ├── ApplicationSpec.js │ ├── DescribeSpec.js │ ├── FutureSpec.js │ ├── ObjectModelSpec.js │ ├── RunnerSpec.js │ ├── ScenarioSpec.js │ ├── SpecRunnerSpec.js │ ├── dslSpec.js │ ├── e2e │ │ ├── Runner-compiled.html │ │ ├── Runner.html │ │ ├── style.css │ │ ├── widgets-scenario.js │ │ └── widgets.html │ ├── jstd-scenario-adapter │ │ └── AdapterSpecs.js │ ├── matchersSpec.js │ ├── mocks.js │ └── output │ │ ├── HtmlSpec.js │ │ ├── jsonSpec.js │ │ ├── objectSpec.js │ │ └── xmlSpec.js ├── testabilityPatch.js └── unit │ ├── controllersSpec.js │ ├── directivesSpec.js │ ├── filtersSpec.js │ └── servicesSpec.js ├── validate-commit-msg.js ├── validate-commit-msg.spec.js ├── version.js ├── version.yaml └── watchr-docs.rb /.env: -------------------------------------------------------------------------------- 1 | PORT=8000 2 | APP_ENV="development" 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | build/ 2 | app/ 3 | app 4 | angularjs.netrc 5 | jstd.log 6 | .DS_Store 7 | gen_docs.disable 8 | test.disable 9 | regression/temp*.html 10 | performance/temp*.html 11 | .idea/workspace.xml 12 | *~ 13 | .*swp 14 | angular.js.tmproj 15 | node_modules 16 | angular.xcodeproj 17 | .idea 18 | .tern-port 19 | logs/* 20 | !.gitkeep 21 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - 0.10 4 | branches: 5 | only: 6 | - master 7 | - dev 8 | notifications: 9 | email: 10 | - rv.maksim@gmail.com 11 | - angularjs.rus@gmail.com 12 | before_script: 13 | - export DISPLAY=:99.0 14 | - sh -e /etc/init.d/xvfb start 15 | - npm install -g grunt-cli 16 | - grunt clean buildall docs uglify copy write compress 17 | script: 18 | - grunt test:unit --browsers Firefox --reporters=dots 19 | - grunt test:e2e --browsers PhantomJS --reporters=dots 20 | after_success: 21 | - if [[ "$TRAVIS_BRANCH" == "dev" ]]; then echo "DEV BRANCH DOESN'T PUSH TO HEROKU"; exit 0; fi 22 | - if [[ "$TRAVIS_BRANCH" == "master" ]]; then 23 | if [[ "$TRAVIS_PULL_REQUEST" != "false" ]]; then exit 0; fi; 24 | wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh; 25 | git remote add heroku git@heroku.com:angular-doc.git; 26 | echo "Host heroku.com" >> ~/.ssh/config; 27 | echo " StrictHostKeyChecking no" >> ~/.ssh/config; 28 | echo " CheckHostIP no" >> ~/.ssh/config; 29 | echo " UserKnownHostsFile=/dev/null" >> ~/.ssh/config; 30 | heroku keys:clear; 31 | yes | heroku keys:add; 32 | yes | git push heroku master; fi 33 | env: 34 | global: 35 | - secure: ! 'YxUgd7mlHqvYwdFBfMr82uoUup48l8RzSToqdX/N/mazZQZjY9e4U7CGuU4j 36 | 37 | 60CoHfZmje4NXWatX7fj0UfJDn53yCSztPNA9t09toLIT3bDbtMSqu3g/AE7 38 | 39 | MPzoXjtlbIXGS6wO4U+zWY+mMyEg2rQftmrjPQugZsvk105LtNM=' 40 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | ## Submitting issues 2 | 3 | If you have questions about how to use AngularJS, please direct these to the 4 | [Google Group][groups] discussion list or [StackOverflow][stackoverflow]. We are 5 | also available on [IRC][irc]. 6 | 7 | ### Guidelines 8 | 9 | * Search the archive first, it's likely that your question was already answered. 10 | * A live example demonstrating your problem or question, will get an answer faster. 11 | * Create one using this [template][template] 12 | * If you get help, help others. Good karma rulez! 13 | 14 | If your issue appears to be a bug, and hasn't been reported, open a new issue. 15 | Help us to maximize the effort we can spend fixing issues and adding new 16 | features, by not reporting duplicate issues. 17 | 18 | [stackoverflow]: http://stackoverflow.com/questions/tagged/angularjs 19 | [groups]: https://groups.google.com/forum/?fromgroups#!forum/angular 20 | [irc]: http://webchat.freenode.net/?channels=angularjs&uio=d4 21 | [template]: http://plnkr.co/edit/gist:3510140 22 | 23 | ## Contributing to Source Code 24 | 25 | We'd love for you to contribute to our source code and to make AngularJS even 26 | better than it is today! 27 | 28 | Please read the [contribution guidelines][contribute] to learn about how to submit code as well as 29 | other useful info like how to build and test AngularJS code. 30 | 31 | [list]: https://groups.google.com/forum/?fromgroups#!forum/angular 32 | [contribute]: http://docs.angularjs.org/misc/contribute 33 | -------------------------------------------------------------------------------- /Guardfile: -------------------------------------------------------------------------------- 1 | # Livereload 2 | 3 | guard 'livereload' do 4 | watch(%r{(app|build|docs/src)/.+\.(css|js|html)}) 5 | end 6 | 7 | guard 'shell' do 8 | watch %r{docs/content/.+\.(ngdoc)} do |f| 9 | puts "" 10 | puts `grunt docs` 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License 2 | 3 | Copyright (c) 2010-2012 Google, Inc. http://angularjs.org 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /Procfile: -------------------------------------------------------------------------------- 1 | web: sh init-app.sh 2 | -------------------------------------------------------------------------------- /README.mdown: -------------------------------------------------------------------------------- 1 | AngularJS 2 | ========= 3 | 4 | AngularJS lets you write client-side web applications as if you had a smarter browser. It lets you 5 | use good old HTML (or HAML, Jade and friends!) as your template language and lets you extend HTML’s 6 | syntax to express your application’s components clearly and succinctly. It automatically 7 | synchronizes data from your UI (view) with your JavaScript objects (model) through 2-way data 8 | binding. To help you structure your application better and make it easy to test, AngularJS teaches 9 | the browser how to do dependency injection and inversion of control. Oh yeah and it also helps with 10 | server-side communication, taming async callbacks with promises and deferreds; and make client-side 11 | navigation and deeplinking with hashbang urls or HTML5 pushState a piece of cake. The best of all: 12 | it makes development fun! 13 | 14 | * Web site: http://angularjs.org 15 | * Tutorial: http://docs.angularjs.org/tutorial 16 | * API Docs: http://docs.angularjs.org/api 17 | * Developer Guide: http://docs.angularjs.org/guide 18 | * Contribution guidelines: http://docs.angularjs.org/misc/contribute 19 | 20 | Building AngularJS 21 | --------- 22 | [Once you have your environment setup](http://docs.angularjs.org/misc/contribute) just run: 23 | 24 | grunt package 25 | 26 | 27 | Running Tests 28 | ------------- 29 | To execute all unit tests, use: 30 | 31 | grunt test:unit 32 | 33 | To execute end-to-end (e2e) tests, use: 34 | 35 | grunt package 36 | grunt test:e2e 37 | 38 | To learn more about the grunt tasks, run `grunt --help` and also read our 39 | [contribution guidelines](http://docs.angularjs.org/misc/contribute). 40 | -------------------------------------------------------------------------------- /changelog.spec.js: -------------------------------------------------------------------------------- 1 | describe('changelog.js', function() { 2 | var ch = require('./changelog'); 3 | 4 | describe('parseRawCommit', function() { 5 | it('should parse raw commit', function() { 6 | var msg = ch.parseRawCommit( 7 | '9b1aff905b638aa274a5fc8f88662df446d374bd\n' + 8 | 'feat(scope): broadcast $destroy event on scope destruction\n' + 9 | 'perf testing shows that in chrome this change adds 5-15% overhead\n' + 10 | 'when destroying 10k nested scopes where each scope has a $destroy listener\n'); 11 | 12 | expect(msg.type).toBe('feat'); 13 | expect(msg.hash).toBe('9b1aff905b638aa274a5fc8f88662df446d374bd'); 14 | expect(msg.subject).toBe('broadcast $destroy event on scope destruction'); 15 | expect(msg.body).toBe('perf testing shows that in chrome this change adds 5-15% overhead\n' + 16 | 'when destroying 10k nested scopes where each scope has a $destroy listener\n') 17 | expect(msg.component).toBe('scope'); 18 | }); 19 | 20 | 21 | it('should parse closed issues', function() { 22 | var msg = ch.parseRawCommit( 23 | '13f31602f396bc269076ab4d389cfd8ca94b20ba\n' + 24 | 'feat(ng-list): Allow custom separator\n' + 25 | 'bla bla bla\n\n' + 26 | 'Closes #123\nCloses #25\n'); 27 | 28 | expect(msg.closes).toEqual([123, 25]); 29 | }); 30 | 31 | 32 | it('should parse breaking changes', function() { 33 | var msg = ch.parseRawCommit( 34 | '13f31602f396bc269076ab4d389cfd8ca94b20ba\n' + 35 | 'feat(ng-list): Allow custom separator\n' + 36 | 'bla bla bla\n\n' + 37 | 'BREAKING CHANGE: first breaking change\nsomething else\n' + 38 | 'another line with more info\n'); 39 | 40 | expect(msg.breaking).toEqual(' first breaking change\nsomething else\nanother line with more info\n'); 41 | }); 42 | }); 43 | }); 44 | -------------------------------------------------------------------------------- /check-size.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | grunt minify 4 | gzip -c < build/angular.min.js > build/angular.min.js.gzip 5 | ls -l build/angular.min.* 6 | -------------------------------------------------------------------------------- /css/angular.css: -------------------------------------------------------------------------------- 1 | @charset "UTF-8"; 2 | 3 | [ng\:cloak], [ng-cloak], [data-ng-cloak], [x-ng-cloak], 4 | .ng-cloak, .x-ng-cloak { 5 | display: none; 6 | } 7 | 8 | ng\:form { 9 | display: block; 10 | } 11 | -------------------------------------------------------------------------------- /docs/content/api/index.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Справочник API 3 | @description 4 | 5 | Используйте справочник API, чтобы узнать больше о конкретной функции. 6 | Для ознакомления с основными понятиями AngularJS обратитесь к 7 | {@link guide/ руководству разработчика}. Если же вы новичок, 8 | рекомендуем начать с {@link tutorial/ учебника}. 9 | 10 | Обратите внимание: значки , стоящие справа от некоторых сервисов, являются ссылками на 11 | соответствующих провайдеров. 12 | -------------------------------------------------------------------------------- /docs/content/api/ng.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name ng 3 | @description 4 | 5 | `ng` это модуль Angular, который содержит все основные сервисы Angular. 6 | -------------------------------------------------------------------------------- /docs/content/cookbook/helloworld.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Cookbook: Привет мир! 3 | @description 4 | 5 | Пример простейшего приложения в Angular 6 | 7 | 8 | 9 | 14 |
15 | Ваше имя: 16 |
17 | Привет, {{name}}! 18 |
19 |
20 | 21 | it('should change the binding when user enters text', function() { 22 | expect(binding('name')).toEqual('мир'); 23 | input('name').enter('angular'); 24 | expect(binding('name')).toEqual('angular'); 25 | }); 26 | 27 |
28 | 29 | # На что следует обратить внимание 30 | 31 | * Тег скрипта, который {@link guide/bootstrap загружает} среду Angular. 32 | * Контроль {@link api/ng.directive:input ввода} текста, связанного с приветствием. 33 | * Нет необходимости регистрировать слушателя и обработчика событий при изменении события. 34 | * Подразумевается наличие переменной `name`, находящейся в корневой {@link api/ng.$rootScope.Scope области видимости}. 35 | * Двойные фигурные скобки `{{markup}}`, связывающие перменную с именем и поздравительный текст. 36 | * Понятие {@link guide/dev_guide.templates.databinding связывания данных}, которое переносит любые изменения в 37 | поле вводв в приветственный текст. 38 | -------------------------------------------------------------------------------- /docs/content/cookbook/module_value.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Cookbook: Настройка модуля (value) 3 | @description 4 | 5 | Использование `value` при настройке модулей 6 | 7 | Пример установки значения во время настройки модуля 8 | 9 | 10 |
11 | {{localText}} 12 | {{globalText}} 13 |
14 |
15 | 16 | var myModule = angular.module('app1', []); 17 | myModule.value('globalText', 'GLOBAL'); 18 | 19 | // Заданное в фазе настройки значение globalText используется в контроллере, 20 | // т.к. оно должно быть привязано к какой-либо области видимости 21 | myModule.controller('MyCtrl', function ($scope, globalText) { 22 | $scope.localText = 'LOCAL'; 23 | $scope.globalText = globalText; 24 | }); 25 | 26 |
27 | 28 | Пример, где значение привязывается к глобальной области видимости 29 | и выводится в методе `run` 30 | 31 | 32 | {{globalText}} 33 |
34 | {{localText}} 35 |
36 |
37 | 38 | var myModule = angular.module('app2', []); 39 | myModule.value('globalText', 'GLOBAL'); 40 | myModule.run(function($rootScope, globalText) { 41 | //Значение устанавливается в глобальной (корневой) области видимости 42 | $rootScope.globalText = globalText; 43 | }); 44 | 45 | myModule.controller('MyCtrl', function($scope) { 46 | $scope.localText = 'LOCAL'; 47 | }); 48 | 49 |
50 | -------------------------------------------------------------------------------- /docs/content/cookbook/tree.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Cookbook: Древовидная структура 3 | @description 4 | 5 | Построение дерева с помощью директивы {@link api/ng.directive:ngRepeat `ngRepeat`} 6 | 7 | 8 | 9 |
10 |
11 |
12 |
13 | 14 | {{data.name}} 15 | 16 | 17 | 20 | 21 | 22 | angular.module("myApp", []); 23 | 24 | function TreeController($scope) { 25 | $scope.delete = function(data) { 26 | data.nodes = []; 27 | }; 28 | $scope.add = function(data) { 29 | var post = data.nodes.length + 1; 30 | var newName = data.name + '-' + post; 31 | data.nodes.push({name: newName,nodes: []}); 32 | }; 33 | $scope.tree = [ 34 | {name: 'Узел', nodes: [ 35 | {name: 'Морской', nodes: []}, 36 | {name: 'Устричный', nodes: []} 37 | ]} 38 | ]; 39 | }; 40 | 41 | 42 | it('не сработало добавление/удаление узла', function() { 43 | element('.add').click(); 44 | expect(repeater('li.node').count()).toEqual(5); 45 | element('.delete').click(); 46 | expect(repeater('li.node').count()).toEqual(0); 47 | }); 48 | 49 |
50 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.mvc.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: MVC в Angular 3 | @description 4 | 5 | Термин Модель–Представление–Контроллер (MVC) с момента создания приобрел различные интерпретации {@link http://martinfowler.com/tags/model-view-controller.html}. Angular по своему использует основные принципы оригинального {@link http://en.wikipedia.org/wiki/Model–view–controller MVC} для построения клиентских веб-приложений. 6 | 7 | Кратко о шаблоне MVC: 8 | 9 | * Разделение приложения на отдельные представления, данные и логику компонентов 10 | * Поощрение слабой связи между этими компонентами 11 | 12 | Вместе с {@link dev_guide.services сервисами} и {@link di внедрением зависимости}, MVC делает Angular-приложения хорошо структурированными, простыми в поддержке и тестировании. 13 | 14 | Следующие разделы описывают, как Angular интерпретирует основные компоненты MVC: 15 | 16 | * {@link dev_guide.mvc.understanding_model Модель} 17 | * {@link dev_guide.mvc.understanding_controller Контроллер} 18 | * {@link dev_guide.mvc.understanding_view Вид} 19 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.mvc.understanding_view.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: MVC в Angular: Вид 3 | @description 4 | 5 | В Angular, видом (или представлением) является DOM загруженный и отображаженный в браузере, после того как Angular преобразовал его 6 | на основе информации в шаблоне, контроллере и модели. 7 | 8 | 9 | 10 | В реализации MVC в Angular, вид знает и о модели, и о контроллере. 11 | Вид знает о модели через двухстороннее связывание данных. Вид знает о контроллере через директивы, такие как {@link api/ng.directive:ngController 12 | ngController} и {@link api/ng.directive:ngView ngView}, и через привязки этой форме: 13 | `{{какаятоФункцияКонтроллера()}}`. В этом смысле, вид может вызывать функции в связанной Функцияи контроллера. 14 | 15 | ## Связанные разделы 16 | 17 | * {@link dev_guide.mvc About MVC в Angular} 18 | * {@link dev_guide.mvc.understanding_model Модель} 19 | * {@link dev_guide.mvc.understanding_controller Контроллер} 20 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.services.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Сервисы Angular 3 | @description 4 | 5 | Сервисы это функции, которые раньше выполнялись только на сервере. Angular же перенес их на клиентскую сторону. 6 | Сервисы в Angular-приложениях являются замещаемыми объектами, которые взаимодействуют друг с другом с помощью 7 | {@link di внедрения зависимости}. 8 | 9 | 10 | ## Связанные разделы 11 | 12 | * {@link dev_guide.services.understanding_services Понимание сервисов} 13 | * {@link dev_guide.services.creating_services Создание сервисов в Angular} 14 | * {@link dev_guide.services.managing_dependencies Управление зависимостями сервисов} 15 | * {@link dev_guide.services.injecting_controllers Внедрение сервисов в контроллеры} 16 | * {@link dev_guide.services.testing_services Тестирование сервисов в Angular} 17 | 18 | ## Связанное API 19 | 20 | * {@link api/ng API сервисов в Angular} 21 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.services.testing_services.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Angular Services: Тестирование сервисов 3 | @description 4 | 5 | Ниже приведен модульный тест для сервиса «notify» в примере «Зависимостей» в разделе {@link 6 | dev_guide.services.creating_services Создание сервисов}. Пример модульного теста использует Jasmine 7 | spy (макет) вместо реальных браузерных сообщений (alert). 8 | 9 |
10 | var mock, notify;
11 | 
12 | beforeEach(function() {
13 |   mock = {alert: jasmine.createSpy()};
14 | 
15 |   module(function($provide) {
16 |     $provide.value('$window', mock);
17 |   });
18 | 
19 |   inject(function($injector) {
20 |     notify = $injector.get('notify');
21 |   });
22 | });
23 | 
24 | it('should not alert first two notifications', function() {
25 |   notify('one');
26 |   notify('two');
27 | 
28 |   expect(mock.alert).not.toHaveBeenCalled();
29 | });
30 | 
31 | it('should alert all after third notification', function() {
32 |   notify('one');
33 |   notify('two');
34 |   notify('three');
35 | 
36 |   expect(mock.alert).toHaveBeenCalledWith("one\ntwo\nthree");
37 | });
38 | 
39 | it('should clear messages after alert', function() {
40 |   notify('one');
41 |   notify('two');
42 |   notify('third');
43 |   notify('more');
44 |   notify('two');
45 |   notify('third');
46 | 
47 |   expect(mock.alert.callCount).toEqual(2);
48 |   expect(mock.alert.mostRecentCall.args).toEqual(["more\ntwo\nthird"]);
49 | });
50 | 
51 | 52 | 53 | ## Связанные разделы 54 | 55 | * {@link dev_guide.services.understanding_services Понимание сервисов} 56 | * {@link dev_guide.services.creating_services Создание сервисов} 57 | * {@link dev_guide.services.managing_dependencies Управление зависимостями сервисов} 58 | * {@link dev_guide.services.injecting_controllers Внедрение сервисов в контроллеры} 59 | 60 | ## Связанное API 61 | 62 | * {@link api/ng API сервисов} 63 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.services.understanding_services.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Сервисы Angular: Понимание сервисов 3 | @description 4 | 5 | Сервисы Angular это одиночки (singletons — классы, у которых есть только один экземпляр), которые выполняют 6 | конкретные задачи, общие для веб-приложений, например, {@link api/ng.$http $http сервис} предоставяет 7 | низкоуровневый доступ к браузерному объекту `XMLHttpRequest`. 8 | 9 | Чтобы использовать сервис Angular, необходимо обозначить его в списке зависимостей контроллера или 10 | другого сервиса. Система внедрения зависимости в Angular позаботится об остальном. Система инжектора отвечает 11 | за создание экземпляра сервиса, разрешение зависимостей и предоставление зависимостей фабричным функциям по запросу. 12 | 13 | Angular внедряет зависимости, используя «конструктор» инъекций (этот сервис передается через фабричную 14 | функцию). Поскольку JavaScript динамически типизированный язык, система внедрения зависимости в Angular 15 | не может использовать статические типы для определения зависимости сервисов. По этой причине необходимо 16 | явно определить зависимости с помощью свойства `$inject`. Например: 17 | 18 | myController.$inject = ['$location']; 19 | 20 | Angular поставляется с сервисами для стандартных операций. Как и другие основные переменные и идентификаторы, 21 | встроенные сервисы всегда начинаются с `$` (например, `$http` упомянутый выше). Также можно создавать свои 22 | собственные сервисы. 23 | 24 | 25 | ## Связанные разделы 26 | 27 | * {@link di Внедрение зависимости в Angular} 28 | * {@link dev_guide.services.creating_services Создание сервисов в Angular} 29 | * {@link dev_guide.services.managing_dependencies Управление зависимостями сервисов} 30 | * {@link dev_guide.services.testing_services Тестирование сервисов в Angular} 31 | 32 | ## Связанное API 33 | 34 | * {@link api/ng API сервисов в Angular} 35 | * {@link api/angular.injector API инжектора} 36 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.templates.css-styling.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Templates: Работа с CSS 3 | @description 4 | 5 | 6 | Angular устанавливает собственные CSS-классы. Это делается для того, чтобы приложение можно было удобно стилизовать. 7 | 8 | # CSS-класс, которые использует Angular 9 | 10 | * `ng-invalid`, `ng-valid` 11 | - **Применение:** Angular применяет этот класс для виджета поля ввода, если введенное значение проходит или не проходит проверку (см. директиву {@link api/ng.directive:input input}). 12 | 13 | * `ng-pristine`, `ng-dirty` 14 | - **Применение:** директива {@link api/ng.directive:input input} применяет класс `ng-pristine` к новым виджетам полей ввода, которые еще не изменялись пользователем. После того как пользователь что-то изменит, класс поменяется на `ng-dirty`. 15 | 16 | ## Связанные разделы 17 | 18 | * {@link dev_guide.templates Шаблоны} 19 | * {@link forms Формы} 20 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.templates.filters.creating_filters.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Templates: Filters: Создание фильтров 3 | @description 4 | 5 | Написать собственный фильтр очень просто: достаточно зарегистрировать новый фильтр (внедренный) фабричной функцией 6 | в ваш модуль. Фабричная функция должна возвращать новую функцию фильтра, которая принимает входное значение 7 | в качестве первого аргумента. Любые аргументы фильтра передаются в качестве дополнительных аргументов в 8 | функцию фильтра. 9 | 10 | Следующий пример фильтра переворачивает текстовую строку. Кроме того, он опционально преобразует текст в 11 | верхний регистр. 12 | 13 | 14 | 15 | 35 | 36 |
37 |
38 | No filter: {{greeting}}
39 | Reverse: {{greeting|reverse}}
40 | Reverse + uppercase: {{greeting|reverse:true}}
41 |
42 |
43 | 44 | it('should reverse greeting', function() { 45 | expect(binding('greeting|reverse')).toEqual('olleh'); 46 | input('greeting').enter('ABC'); 47 | expect(binding('greeting|reverse')).toEqual('CBA'); 48 | }); 49 | 50 |
51 | 52 | 53 | ## Связанные разделы 54 | 55 | * {@link dev_guide.templates.filters Фильтры} 56 | * {@link compiler HTML-компилятор в Angular} 57 | 58 | ## Связанное API 59 | 60 | * {@link api/ng.$filter API фильтров} 61 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.templates.filters.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Templates: Фильтры 3 | @description 4 | 5 | Фильтры в Angular форматируют данные для отображения пользователю. 6 | 7 | Например, имеется объект данных, который должен быть отформатирован в соответствии с языковыми настройками, прежде чем 8 | он будет показан пользователю. Можно передать выражения через цепочку фильтров следующим образом: 9 | 10 | name | uppercase 11 | 12 | Анализатор выражения просто передает значение name в фильтр {@link api/ng.filter:uppercase uppercase}. 13 | 14 | 15 | ## Связанные разделы 16 | 17 | * {@link dev_guide.templates.filters.using_filters Использование фильтров} 18 | * {@link dev_guide.templates.filters.creating_filters Создание фильтров} 19 | 20 | ## Связанное API 21 | 22 | * {@link api/ng.$filter API фильтров} 23 | -------------------------------------------------------------------------------- /docs/content/guide/dev_guide.templates.filters.using_filters.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Templates: Filters: Применение фильтров 3 | @description 4 | 5 | Фильтры могут быть частью вычисления любой {@link api/ng.$rootScope.Scope области видимости}, но, как правило, используются для форматирования 6 | выражений в связанных шаблонах: 7 | 8 | {{ expression | filter }} 9 | 10 | Фильтры, как правило, преобразуют данные из одного типа в другой, форматируя их в процессе. 11 | Фильтры могут быть соединены в цепочку, и могут принимать дополнительные аргументы. 12 | 13 | Можно объединить фильтры, используя следующий синтаксис: 14 | 15 | {{ expression | filter1 | filter2 }} 16 | 17 | Также можно передать через двоеточие аргументы, например, для отображения номера 123 с двумя знаками после запятой: 18 | 19 | 123 | number:2 20 | 21 | Тот же синтаксис используется для передачи нескольких аргументов: 22 | 23 | myArray | orderBy:'timestamp':true 24 | 25 | Несколько примеров, которые показывают значения до и после применения различных фильтров к связанным выражениям: 26 | 27 | * Без фильтра: `{{1234.5678}}` => `1234.5678` 28 | * Числовой фильтр: `{{1234.5678|number}}` => `1,234.57`. Заметьте "," и округление до двух знаков. 29 | * Фильтр с аргументами: `{{1234.5678|number:5}}` => `1,234.56780`. Filters can take optional 30 | arguments, separated by colons in a binding. For example, the "number" filter takes a number 31 | argument that specifies how many digits to display to the right of the decimal point. 32 | 33 | Фильтры могут дополнительно принять аргументы, разделенные двоеточиями в связке. Например, числовой фильтр принимает числовой 34 | аргумент, который определяет, сколько цифр показывать после запятой. 35 | 36 | 37 | ## Связанные разделы 38 | 39 | * {@link dev_guide.templates.filters Понимание фильтров} 40 | * {@link dev_guide.templates.filters.creating_filters Создание фильтров} 41 | 42 | ## Связанное API 43 | 44 | * {@link api/ng.$filter API фильтров} 45 | -------------------------------------------------------------------------------- /docs/content/guide/index.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Руководство разработчика 3 | @description 4 | 5 | Добро пожаловать в руководство разработчика Angular. Если вы здесь, чтобы получше узнать, как использовать 6 | Angular для разработки веб-приложений, то вы в нужном месте. 7 | 8 | Если вы пока плохо знакомы с Angular, то перед прочтением этого руководства, 9 | будет не лишним ознакомиться со следующими материалами: 10 | 11 | * {@link misc/started С чего начать} 12 | * {@link tutorial/index Учебник Angular} 13 | -------------------------------------------------------------------------------- /docs/content/guide/type.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Developer Guide: Тип 3 | @description 4 | -------------------------------------------------------------------------------- /docs/content/tutorial/the_end.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name Tutorial: Заключение 3 | @description 4 | 5 | Итак, наше приложение готово! Теперь вы можете дописать в него что-то новое, или в любой момент 6 | откатиться назад с помощью команды `git checkout`. 7 | 8 | Чтобы подробнее рассмотреть темы, которых мы едва коснулись в этом учебнике, обратитесь к 9 | {@link guide/ Руководству разработчика}. 10 | 11 | Примеры кода можно найти в {@link cookbook/ Рецептах}. 12 | 13 | Когда будете готовы разрабатывать собственное приложение на Angular, рекомендуем взять за основу 14 | {@link https://github.com/angular/angular-seed шаблонное приложение Angular}. 15 | 16 | Надеемся, что этот учебник был полезен и вы узнали достаточно нового, чтобы захотеть узнать об Angular 17 | ещё больше. Очень надеемся, что вдохновили вас на создание собственных angular-приложений, а также на то, 18 | что вы может быть заинтересуетесь в {@link misc/contribute участии в разработке Angular}. 19 | 20 | Если у вас остались какие-либо вопросы, желаете получить обратную связь по каким-либо вопросам, или просто 21 | хотите сказать нам «Привет!», не стесняйтесь, оставляйте сообщение в {@link 22 | https://groups.google.com/forum/#!forum/angular Группе сообщества Angular}. 23 | -------------------------------------------------------------------------------- /docs/content/ui/compatibility.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name UI-Router: Обратная совместимость 3 | @description 4 | 5 | Полная обратная совместимость с $routeProvider **не является** основной целью этого проекта. Тем не менее, 6 | мы пытаемся обозначить четкий путь перехода от $routeProvider к $stateProvider, а также использовать совместимую 7 | терминологию, где это возможно и имеет смысл. На данный момент, большинство функций $routeProvider прямо сопоставлены 8 | подмножеству функциональности $stateProvider, так что обеспечивается совместимость, которая позволяет переносить 9 | приложения по крупицам. 10 | -------------------------------------------------------------------------------- /docs/content/ui/components.ngdoc: -------------------------------------------------------------------------------- 1 | @ngdoc overview 2 | @name UI-Router: Компоненты 3 | @description 4 | 5 | * **$state** / **$stateProvider**: управляет определениями состояний, текущего состояния и переходов в состояния. 6 | Включает в себя запуск связанных с переходом событий и колбэков, асинхронное разрешение любых зависимостей целевого 7 | состояния и обновление $location для отображения текущего состояния. Для состояний, к которым привязан URL-адрес, 8 | как правило, автоматически регистрируется $urlRouterProvider, выполняющий переход к этому состоянию. 9 | * директива **ui-view**: рендерит виды, определенные в текущем состоянии. По существу, директивы ui-view (которым 10 | можно так же задать свои имена) являются местами, куда вставляются виды, определенными в текущем состоянии. 11 | * **$urlRouter** / **$urlRouterProvider**: управляет списком _правил_, которые сопоставляются с $location при каждом 12 | его изменении. На самом низком уровне, правило может быть произвольной функцией, проверяющей $location и возвращающей 13 | истину, если было изменение. Поддержка предоставляется на вершине этого правила для RegExp и URL-шаблонов, которые 14 | компилируются в объекты UrlMatcher с помощью $urlMatcherFactory. 15 | * **$urlMatcherFactory**: компилирует шаблоны URL с заполнителями в объекты UrlMatcher. В дополнение к синтаксису 16 | заполнителей, поддерживаемому $routeProvider, также поддерживает расширенный синтаксис, который позволяет задавать 17 | заполнитель регулярным выражением, и может извлечь имена параметров из части URL, содержащей запросы. 18 | * **$templateFactory**: загружает шаблоны через $http / $templateCache. Используется $state. 19 | -------------------------------------------------------------------------------- /docs/img/AngularJS-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/AngularJS-small.png -------------------------------------------------------------------------------- /docs/img/One_Way_Data_Binding.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/One_Way_Data_Binding.png -------------------------------------------------------------------------------- /docs/img/Two_Way_Data_Binding.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/Two_Way_Data_Binding.png -------------------------------------------------------------------------------- /docs/img/angular_parts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/angular_parts.png -------------------------------------------------------------------------------- /docs/img/bullet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/bullet.png -------------------------------------------------------------------------------- /docs/img/form_data_flow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/form_data_flow.png -------------------------------------------------------------------------------- /docs/img/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /docs/img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /docs/img/guide/about_model_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/about_model_final.png -------------------------------------------------------------------------------- /docs/img/guide/about_view_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/about_view_final.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-controller.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-controller.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-directive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-directive.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-model.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-module-injector.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-module-injector.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-runtime.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-runtime.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-scope.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-scope.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-startup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-startup.png -------------------------------------------------------------------------------- /docs/img/guide/concepts-view.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/concepts-view.png -------------------------------------------------------------------------------- /docs/img/guide/di_sequence_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/di_sequence_final.png -------------------------------------------------------------------------------- /docs/img/guide/dom_scope_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/dom_scope_final.png -------------------------------------------------------------------------------- /docs/img/guide/hashbang_vs_regular_url.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/hashbang_vs_regular_url.jpg -------------------------------------------------------------------------------- /docs/img/guide/scenario_runner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/scenario_runner.png -------------------------------------------------------------------------------- /docs/img/guide/simple_scope_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/guide/simple_scope_final.png -------------------------------------------------------------------------------- /docs/img/helloworld.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/helloworld.png -------------------------------------------------------------------------------- /docs/img/helloworld_2way.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/helloworld_2way.png -------------------------------------------------------------------------------- /docs/img/tutorial/catalog_screen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/catalog_screen.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_00.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_00_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_00_final.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_02.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_03.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_04.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_07_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_07_final.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_08-09_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_08-09_final.png -------------------------------------------------------------------------------- /docs/img/tutorial/tutorial_10-11_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/tutorial_10-11_final.png -------------------------------------------------------------------------------- /docs/img/tutorial/xhr_service_final.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/img/tutorial/xhr_service_final.png -------------------------------------------------------------------------------- /docs/spec/domSpec.js: -------------------------------------------------------------------------------- 1 | var DOM = require('../src/dom.js').DOM; 2 | 3 | describe('dom', function() { 4 | var dom; 5 | 6 | beforeEach(function() { 7 | dom = new DOM(); 8 | }); 9 | 10 | describe('h', function() { 11 | 12 | it('should render using function', function() { 13 | var cbThis; 14 | var cdValue; 15 | dom.h('heading', 'content', function(value){ 16 | cbThis = this; 17 | cbValue = value; 18 | }); 19 | expect(cbThis).toEqual(dom); 20 | expect(cbValue).toEqual('content'); 21 | }); 22 | 23 | it('should update heading numbers', function() { 24 | dom.h('heading', function() { 25 | this.html('

sub-heading

'); 26 | }); 27 | expect(dom.toString()).toContain('

heading

'); 28 | expect(dom.toString()).toContain('

sub-heading

'); 29 | }); 30 | 31 | }); 32 | 33 | }); 34 | -------------------------------------------------------------------------------- /docs/spec/sitemapSpec.js: -------------------------------------------------------------------------------- 1 | var SiteMap = require('../src/SiteMap.js').SiteMap; 2 | var Doc = require('../src/ngdoc.js').Doc; 3 | 4 | 5 | describe('sitemap', function() { 6 | it('should render empty sitemap', function() { 7 | var map = new SiteMap([]); 8 | expect(map.render()).toEqual([ 9 | '', 10 | '', 11 | '', ''].join('\n')); 12 | }); 13 | 14 | it('should render ngdoc url', function() { 15 | var map = new SiteMap([new Doc({section: 'foo', id: 'a.b.c<>\'"&'})]); 16 | expect(map.render()).toContain([ 17 | ' ', 18 | 'http://docs.angularjs.org/foo/a.b.c<>'"&', 19 | 'weekly', 20 | ''].join('')); 21 | 22 | }); 23 | }); 24 | -------------------------------------------------------------------------------- /docs/spec/specs.js: -------------------------------------------------------------------------------- 1 | if (global.jasmine) return; 2 | 3 | var jasmine = require('../../lib/jasmine-1.0.1'); 4 | 5 | for(var key in jasmine) { 6 | global[key] = jasmine[key]; 7 | } 8 | 9 | //Patch Jasmine for proper stack traces 10 | jasmine.Spec.prototype.fail = function(e) { 11 | var expectationResult = new jasmine.ExpectationResult({ 12 | passed: false, 13 | message: e ? jasmine.util.formatException(e) : 'Exception' 14 | }); 15 | // PATCH 16 | if (e) { 17 | expectationResult.trace = e; 18 | } 19 | this.results_.addResult(expectationResult); 20 | }; 21 | 22 | 23 | 24 | var isVerbose = false; 25 | var showColors = true; 26 | process.argv.forEach(function(arg){ 27 | switch(arg) { 28 | case '--color': showColors = true; break; 29 | case '--noColor': showColors = false; break; 30 | case '--verbose': isVerbose = true; break; 31 | } 32 | }); 33 | 34 | jasmine.executeSpecsInFolder(__dirname, function(runner, log){ 35 | process.exit(runner.results().failedCount); 36 | }, isVerbose, showColors); 37 | -------------------------------------------------------------------------------- /docs/spec/writerSpec.js: -------------------------------------------------------------------------------- 1 | var writer = require('../src/writer.js'); 2 | describe('writer', function() { 3 | describe('toString', function() { 4 | var toString = writer.toString; 5 | 6 | it('should merge string', function() { 7 | expect(toString('abc')).toEqual('abc'); 8 | }); 9 | 10 | it('should merge obj', function() { 11 | expect(toString({a:1})).toEqual('{"a":1}'); 12 | }); 13 | 14 | it('should merge array', function() { 15 | expect(toString(['abc',{}])).toEqual('abc{}'); 16 | }); 17 | }); 18 | 19 | describe('replace method', function() { 20 | var content, 21 | replacements; 22 | 23 | beforeEach(function() { 24 | content = 'angular super jQuery manifest'; 25 | }); 26 | 27 | it('should replace placeholders', function() { 28 | replacements = {'angular': 'ng', 'jQuery': 'jqlite','notHere': 'here'}; 29 | 30 | content = writer.replace(content, replacements); 31 | expect(content).toBe('ng super jqlite manifest'); 32 | }); 33 | }); 34 | }); 35 | -------------------------------------------------------------------------------- /docs/src/SiteMap.js: -------------------------------------------------------------------------------- 1 | exports.SiteMap = SiteMap; 2 | 3 | /** 4 | * @see http://www.sitemaps.org/protocol.php 5 | * 6 | * @param docs 7 | * @returns {SiteMap} 8 | */ 9 | function SiteMap(docs){ 10 | this.render = function() { 11 | var map = []; 12 | map.push(''); 13 | map.push(''); 14 | docs.forEach(function(doc){ 15 | map.push(' http://docs.angularjs.org/' + 16 | encode(doc.section) + '/' + 17 | encode(doc.id) + 18 | 'weekly'); 19 | }); 20 | map.push(''); 21 | map.push(''); 22 | return map.join('\n'); 23 | }; 24 | 25 | function encode(text){ 26 | return text 27 | .replace(/&/mg, '&') 28 | .replace(//mg, '>') 30 | .replace(/'/mg, ''') 31 | .replace(/"/mg, '"'); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /docs/src/ignore.words: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/ignore.words -------------------------------------------------------------------------------- /docs/src/templates/.htaccess: -------------------------------------------------------------------------------- 1 | ## OFFLINE SUPPORT ## 2 | 3 | # These rules tell apache to check if there is a cookie called "offline", with value set to the 4 | # current angular version. If this rule matches the appcache-offline.manifest will be served for 5 | # requests to appcache.manifest 6 | # 7 | # This file must be processed by Grunt in order to replace %ANGULAR_VERSION% with the actual version. 8 | 9 | Options -Indexes 10 | RewriteEngine on 11 | RewriteCond %{HTTP_COOKIE} ng-offline="NG_VERSION_FULL" 12 | RewriteRule appcache.manifest appcache-offline.manifest 13 | 14 | ## Redirect to the latest manifest 15 | RewriteCond %{HTTP_HOST} ^docs-next\.angularjs\.org$ 16 | RewriteRule appcache.manifest http://code.angularjs.org/next/docs/appcache.manifest [R=301] 17 | 18 | ## HTML5 URL Support ## 19 | RewriteRule ^(guide|api|cookbook|misc|tutorial)(/.*)?$ index.html 20 | -------------------------------------------------------------------------------- /docs/src/templates/docs-scenario.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | AngularJS Docs E2E Test Runner 5 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /docs/src/templates/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/templates/favicon.ico -------------------------------------------------------------------------------- /docs/src/templates/font/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/templates/font/fontawesome-webfont.eot -------------------------------------------------------------------------------- /docs/src/templates/font/fontawesome-webfont.svgz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/templates/font/fontawesome-webfont.svgz -------------------------------------------------------------------------------- /docs/src/templates/font/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/templates/font/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /docs/src/templates/font/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/docs/src/templates/font/fontawesome-webfont.woff -------------------------------------------------------------------------------- /docs/src/templates/js/jquery.js: -------------------------------------------------------------------------------- 1 | ../../../../lib/jquery/jquery.js -------------------------------------------------------------------------------- /docs/src/templates/js/jquery.min.js: -------------------------------------------------------------------------------- 1 | ../../../../lib/jquery/jquery.min.js -------------------------------------------------------------------------------- /docs/src/templates/offline.html: -------------------------------------------------------------------------------- 1 |

OFFLINE

2 | 3 |

This page is currently unavailable because your are offline.

4 |

Please connect to the Internet and reload the page.

5 | -------------------------------------------------------------------------------- /example/buzz/buzz.css: -------------------------------------------------------------------------------- 1 | body { 2 | background: -webkit-gradient(linear, left top, left 100, from(#bbb), to(#fff)); 3 | background-repeat: no-repeat; 4 | margin: 0px; 5 | font-family: sans-serif; 6 | font-size: 12px; 7 | } 8 | 9 | body > div { 10 | border-top: 1px solid white; 11 | border-bottom: 1px solid black; 12 | text-align: center; 13 | background: -webkit-gradient(linear, left top, left bottom, from(#CCC), to(#888)); 14 | -webkit-background-origin: padding; -webkit-background-clip: content; 15 | } 16 | body > div button { 17 | margin: 5px; 18 | } 19 | 20 | body > div span:FIRST-CHILD { 21 | float: left; 22 | font-family: monospace; 23 | font-size: 1.5em; 24 | color: black; 25 | padding: 2px 5px; 26 | } 27 | 28 | body > div span:last-child { 29 | float: right; 30 | } 31 | 32 | ul { 33 | list-style: none; 34 | padding: 10px; 35 | margin: 0; 36 | } 37 | 38 | body > ul > li { 39 | border: 1px solid black; 40 | margin: 15px 5px; 41 | padding: 0; 42 | -webkit-box-shadow: 5px 5px 5px #888; 43 | } 44 | 45 | body > ul > li > h1 { 46 | margin: 0; 47 | background: -webkit-gradient(linear, left top, left bottom, from(#ddd), to(#999)); 48 | font-size: 13px; 49 | border-bottom: 1px solid black; 50 | } 51 | 52 | h1 > img, 53 | li > img { 54 | max-height: 30px; 55 | max-width: 30px; 56 | vertical-align: middle; 57 | padding: 3px; 58 | } 59 | 60 | a > img { 61 | margin-right: 5px; 62 | margin-top: 5px; 63 | } 64 | 65 | body > ul > li > h1 > a:last-child { 66 | float: right; 67 | margin: 10px; 68 | } 69 | 70 | body > ul > li > div { 71 | background-color: white; 72 | background: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#ddd)); 73 | margin: 0; 74 | padding: 10px; 75 | } 76 | 77 | body > ul > li ul { 78 | margin: 0; 79 | padding: 0; 80 | margin-left: 5px; 81 | border-left: 5px solid lightgray; 82 | } 83 | 84 | body > ul > li ul > li { 85 | margin: 0; 86 | padding: 10px; 87 | background: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#ddd)); 88 | } 89 | 90 | -------------------------------------------------------------------------------- /example/buzz/buzz.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | <angular/> Buzz 13 | 14 | filter: 15 | 16 | 17 | 18 | user: 19 | 20 | 21 | 22 |
23 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /example/buzz/buzz.js: -------------------------------------------------------------------------------- 1 | angular.module.ng('myApplication', function($resource){ 2 | this.Activity = $resource( 3 | 'https://www.googleapis.com/buzz/v1/activities/:userId/:visibility/:activityId/:comments', 4 | {alt:'json', callback:'JSON_CALLBACK'}, 5 | { 6 | get: {method:'JSON', params:{visibility:'@self'}}, 7 | replies: {method:'JSON', params:{visibility:'@self', comments:'@comments'}} 8 | }); 9 | }, {inject:['$resource']}); 10 | 11 | function BuzzController() { 12 | this.$watch('$location.hashPath', this.userChange); 13 | } 14 | BuzzController.prototype = { 15 | userChange: function() { 16 | this.userId = this.$location.hashPath; 17 | this.activities = this.Activity.get({userId:this.userId}); 18 | }, 19 | 20 | expandReplies: function(activity) { 21 | var self = this; 22 | if (activity.replies) { 23 | activity.replies.show = !activity.replies.show; 24 | } else { 25 | activity.replies = this.Activity.replies({userId:this.userId, activityId:activity.id}, function() { 26 | activity.replies.show = true; 27 | }); 28 | } 29 | } 30 | }; 31 | 32 | angular.widget('my:expand', function(element){ 33 | element.css('display', 'block'); 34 | this.descend(true); 35 | return function(element) { 36 | element.hide(); 37 | var watch = element.attr('expand'); 38 | this.$watch(watch, function(value){ 39 | if (value) { 40 | element.delay(0).slideDown('slow'); 41 | } else { 42 | element.slideUp('slow'); 43 | } 44 | }); 45 | }; 46 | }); 47 | -------------------------------------------------------------------------------- /example/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /example/personalLog/personalLog.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Personal Log 5 | 6 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 |
22 | 23 |
24 |

Logs:

25 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /example/personalLog/scenario/runner.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Personal Log Scenario Runner 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /example/temp.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | angular dev sandbox 5 | 6 | 19 | 20 | 21 | 22 |

23 | view1 | view2 | blank 24 |

25 | 26 |
27 | 28 |
29 | 30 | 31 | -------------------------------------------------------------------------------- /example/tweeter/style.css: -------------------------------------------------------------------------------- 1 | .loading {display: none;} 2 | .fetching .loading {display: block;} 3 | 4 | a { 5 | color: blue; 6 | } 7 | 8 | h1 { 9 | background-color: black; 10 | margin: 0; 11 | padding: .25em; 12 | color: white; 13 | border-bottom: 5px solid gray; 14 | } 15 | 16 | .box { 17 | border: 2px solid gray; 18 | } 19 | 20 | .tweeter { 21 | margin-right: 360px; 22 | } 23 | 24 | ul { 25 | list-style: none; 26 | margin: 0; 27 | padding: 0; 28 | } 29 | 30 | li { 31 | margin: .25em; 32 | padding: 2px; 33 | } 34 | 35 | li img { 36 | float: left; 37 | margin: 2px; 38 | margin-right: .5em; 39 | max-height: 48px; 40 | min-height: 48px; 41 | } 42 | 43 | li.even { 44 | background-color: lightgray; 45 | } 46 | 47 | 48 | .addressbook { 49 | float: right; 50 | width: 350px; 51 | } 52 | 53 | .addressbook li { 54 | font-size: .9em; 55 | } 56 | 57 | .clrleft { 58 | clear: left; 59 | } 60 | 61 | .notes { 62 | font-size: .8em; 63 | color: gray; 64 | } 65 | 66 | .username, .nickname { 67 | font-weight: bold; 68 | } 69 | 70 | .editor { 71 | padding: 4px; 72 | } 73 | 74 | label { 75 | color: gray; 76 | display: inline-block; 77 | width: 75px; 78 | text-align: right; 79 | padding: 2px; 80 | margin-top: 10px; 81 | } 82 | 83 | .editor input[type=text], 84 | .editor textarea { 85 | width: 230px; 86 | vertical-align: text-top; 87 | } 88 | 89 | .editor TEXTAREA { 90 | height: 50px; 91 | } 92 | 93 | .debug{ 94 | font-size: .7em; 95 | white-space: pre; 96 | padding: 0; 97 | margin: 0; 98 | } -------------------------------------------------------------------------------- /example/tweeter/tweeter_demo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | (TODO: I should fetch current tweets) 13 |
14 |

Tweets: {{$anchor.user}}

15 | [ Filter: (TODO: this should act as search box) 16 | | << All 17 | ] 18 |
Loading...
19 | 31 |
32 |
tweets=(TODO: display me!!!)
33 | 34 | 35 | -------------------------------------------------------------------------------- /example/tweeter/tweeterclient.js: -------------------------------------------------------------------------------- 1 | function noop() {} 2 | $(document).ready(function() { 3 | function xhr(method, url, data, callback){ 4 | jQuery.getJSON(url, function() { 5 | callback.apply(this, arguments); 6 | scope.updateView(); 7 | }); 8 | } 9 | 10 | var resourceFactory = new ResourceFactory(xhr); 11 | 12 | var Tweeter = resourceFactory.route("http://twitter.com/statuses/:service:username.json", {}, { 13 | home: {method:'GET', params: {service:'home_timeline'}, isArray:true }, 14 | user: {method:'GET', params: {service:'user_timeline/'}, isArray:true } 15 | }); 16 | 17 | 18 | var scope = window.scope = angular.compile(document, { 19 | location:angular.startUrlWatcher() 20 | }); 21 | 22 | function fetchTweets(username){ 23 | return username ? Tweeter.user({username: username}) : Tweeter.home(); 24 | } 25 | 26 | scope.set('fetchTweets', fetchTweets); 27 | scope.set('users', [ 28 | {screen_name:'mhevery', name:'Mi\u0161ko Hevery', 29 | notes:'Author of http://www.getangular.com.', 30 | profile_image_url:'http://a3.twimg.com/profile_images/54360179/Me_-_Small_Banner_normal.jpg'}, 31 | {screen_name:'abrons', name:'Adam Abrons', 32 | notes:'Author of & Ruby guru see: http://www.angularjs.org.', 33 | profile_image_url:'http://media.linkedin.com/mpr/mpr/shrink_80_80/p/2/000/005/0a8/044278d.jpg'} 34 | ]); 35 | scope.init(); 36 | }); 37 | -------------------------------------------------------------------------------- /example/view1.html: -------------------------------------------------------------------------------- 1 | view1
2 | location: {{url()}} 3 | -------------------------------------------------------------------------------- /example/view2.html: -------------------------------------------------------------------------------- 1 | view2
2 | location: {{url()}}
3 | -------------------------------------------------------------------------------- /gen_docs.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | JASMINE_NODE='jasmine-node' 4 | local_jasmine='./node_modules/.bin/jasmine-node' 5 | 6 | if ! type -p "$JASMINE_NODE" >/dev/null 2>&1;then 7 | if [[ -x "$local_jasmine" ]];then 8 | JASMINE_NODE="$local_jasmine" 9 | else 10 | echo 'Could not find a locally or globally installed executable of' \ 11 | 'jasmine-node. Try: `npm install jasmine-node`.' >&2 12 | exit 1 13 | fi 14 | fi 15 | 16 | if [[ ! -e gen_docs.disable ]]; then 17 | echo 'Testing, then building documentation...' 18 | "$JASMINE_NODE" docs/spec --noColor && node docs/src/gen-docs.js 19 | fi 20 | -------------------------------------------------------------------------------- /home/app.yaml: -------------------------------------------------------------------------------- 1 | application: angularjsorg 2 | version: 1 3 | runtime: python27 4 | api_version: 1 5 | threadsafe: yes 6 | 7 | handlers: 8 | - url: /favicon\.ico 9 | static_files: favicon.ico 10 | upload: favicon\.ico 11 | 12 | - url: /appcache.manifest 13 | static_files: appcache.manifest 14 | upload: appcache\.manifest 15 | 16 | - url: / 17 | static_files: index.html 18 | upload: index.html 19 | 20 | - url: /css 21 | static_dir: css 22 | 23 | - url: /font 24 | static_dir: font 25 | 26 | - url: /google-code-prettify 27 | static_dir: google-code-prettify 28 | 29 | - url: /img 30 | static_dir: img 31 | 32 | - url: /js 33 | static_dir: js 34 | 35 | - url: /(greet|generatePassword)(\.php)? 36 | script: demos.app 37 | 38 | - url: /.* 39 | static_files: index.html 40 | upload: index.html 41 | 42 | libraries: 43 | - name: webapp2 44 | version: "2.5.1" 45 | -------------------------------------------------------------------------------- /home/appcache.manifest: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/appcache.manifest -------------------------------------------------------------------------------- /home/demos.py: -------------------------------------------------------------------------------- 1 | # coding: utf-8 2 | 3 | import webapp2, random, json, string 4 | 5 | SALUTATIONS = [ "Adab", "Ahoj", "An-nyeong-ha-se-yo", "Apa khabar", "Barev Dzez", u"Buenos días".encode('utf-8'), "Bula Vinaka", 6 | "Chào", "Ciao", "Dia Duit", "Hallo", "Hallå", "Halló", "Halo", "Haye", "Hei", "Hej", "Hello", 7 | "Helo", "Hola", "Kamusta", "Konnichiwa", "Merhaba", "Mingalarba", "Namaskar", "Namaste", "Olá", 8 | "Pryvit", "Pryvitannie", "Përshëndetje", "Salam", "Salut", "Sat Sri Akal", "Sholem aleikhem", 9 | "Sveiki", "Szia", "Tere", "Zdraveĭte", "Zdravo" ] 10 | 11 | 12 | class GreetHandler(webapp2.RequestHandler): 13 | def get(self): 14 | name = self.request.get('name') 15 | callback = self.request.get('callback') 16 | salutation = SALUTATIONS[random.randint(0, len(SALUTATIONS) - 1)].encode('string_escape') 17 | greeting = json.dumps([name, salutation, salutation + ' ' + name + '!']) 18 | 19 | self.response.headers['Content-Type'] = 'application/javascript' 20 | self.response.out.write(callback + '(' + greeting + ')') 21 | 22 | 23 | class GeneratePasswordHandler(webapp2.RequestHandler): 24 | def get(self): 25 | callback = self.request.get('callback') 26 | password = ''.join(random.choice(string.hexdigits) for x in range(random.randint(3, 10))) 27 | password = json.dumps({'password': password}) 28 | self.response.headers['Content-Type'] = 'application/javascript' 29 | self.response.out.write(callback + '(' + password + ')') 30 | 31 | 32 | app = webapp2.WSGIApplication([('/greet.*', GreetHandler), 33 | ('/generatePassword.*', GeneratePasswordHandler)]) 34 | -------------------------------------------------------------------------------- /home/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/favicon.ico -------------------------------------------------------------------------------- /home/font/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/font/fontawesome-webfont.eot -------------------------------------------------------------------------------- /home/font/fontawesome-webfont.svgz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/font/fontawesome-webfont.svgz -------------------------------------------------------------------------------- /home/font/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/font/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /home/font/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/font/fontawesome-webfont.woff -------------------------------------------------------------------------------- /home/generatePassword.php: -------------------------------------------------------------------------------- 1 | 0; $counter --) { 5 | $password = $password . chr(rand(33, 126)); 6 | } 7 | $data = array( 8 | "password" => $password ); 9 | $json = json_encode($data); 10 | header("Content-type: text/javascript"); 11 | if ($callback) 12 | echo $callback .' (' . $json . ');'; 13 | else 14 | echo $json; 15 | ?> -------------------------------------------------------------------------------- /home/gitFetchSite.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | Update site from: GitHub master 4 | 5 | 6 | > gitFetchSite.log`; ?> 7 | > gitFetchSite.log`; ?> 8 |
9 |
10 |
11 |
12 |
13 | > gitFetchSite.log`; ?> 14 | 15 | 16 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-apollo.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["com",/^#[^\n\r]*/,null,"#"],["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,null,'"']],[["kwd",/^(?:ADS|AD|AUG|BZF|BZMF|CAE|CAF|CA|CCS|COM|CS|DAS|DCA|DCOM|DCS|DDOUBL|DIM|DOUBLE|DTCB|DTCF|DV|DXCH|EDRUPT|EXTEND|INCR|INDEX|NDX|INHINT|LXCH|MASK|MSK|MP|MSU|NOOP|OVSK|QXCH|RAND|READ|RELINT|RESUME|RETURN|ROR|RXOR|SQUARE|SU|TCR|TCAA|OVSK|TCF|TC|TS|WAND|WOR|WRITE|XCH|XLQ|XXALQ|ZL|ZQ|ADD|ADZ|SUB|SUZ|MPY|MPR|MPZ|DVP|COM|ABS|CLA|CLZ|LDQ|STO|STQ|ALS|LLS|LRS|TRA|TSQ|TMI|TOV|AXT|TIX|DLY|INP|OUT)\s/, 2 | null],["typ",/^(?:-?GENADR|=MINUS|2BCADR|VN|BOF|MM|-?2CADR|-?[1-6]DNADR|ADRES|BBCON|[ES]?BANK=?|BLOCK|BNKSUM|E?CADR|COUNT\*?|2?DEC\*?|-?DNCHAN|-?DNPTR|EQUALS|ERASE|MEMORY|2?OCT|REMADR|SETLOC|SUBRO|ORG|BSS|BES|SYN|EQU|DEFINE|END)\s/,null],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[!-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["apollo","agc","aea"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-clj.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (C) 2011 Google Inc. 3 | 4 | Licensed under the Apache License, Version 2.0 (the "License"); 5 | you may not use this file except in compliance with the License. 6 | You may obtain a copy of the License at 7 | 8 | http://www.apache.org/licenses/LICENSE-2.0 9 | 10 | Unless required by applicable law or agreed to in writing, software 11 | distributed under the License is distributed on an "AS IS" BASIS, 12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | See the License for the specific language governing permissions and 14 | limitations under the License. 15 | */ 16 | var a=null; 17 | PR.registerLangHandler(PR.createSimpleLexer([["opn",/^[([{]+/,a,"([{"],["clo",/^[)\]}]+/,a,")]}"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a,"\t\n\r \u00a0"],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:def|if|do|let|quote|var|fn|loop|recur|throw|try|monitor-enter|monitor-exit|defmacro|defn|defn-|macroexpand|macroexpand-1|for|doseq|dosync|dotimes|and|or|when|not|assert|doto|proxy|defstruct|first|rest|cons|defprotocol|deftype|defrecord|reify|defmulti|defmethod|meta|with-meta|ns|in-ns|create-ns|import|intern|refer|alias|namespace|resolve|ref|deref|refset|new|set!|memfn|to-array|into-array|aset|gen-class|reduce|map|filter|find|nil?|empty?|hash-map|hash-set|vec|vector|seq|flatten|reverse|assoc|dissoc|list|list?|disj|get|union|difference|intersection|extend|extend-type|extend-protocol|prn)\b/,a], 18 | ["typ",/^:[\dA-Za-z-]+/]]),["clj"]); 19 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-css.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\n\u000c"]],[["str",/^"(?:[^\n\f\r"\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*"/,null],["str",/^'(?:[^\n\f\r'\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*'/,null],["lang-css-str",/^url\(([^"')]+)\)/i],["kwd",/^(?:url|rgb|!important|@import|@page|@media|@charset|inherit)(?=[^\w-]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*)\s*:/i],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//], 2 | ["com",/^(?:<\!--|--\>)/],["lit",/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],["lit",/^#[\da-f]{3,6}/i],["pln",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i],["pun",/^[^\s\w"']+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[["kwd",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[["str",/^[^"')]+/]]),["css-str"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-go.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["pln",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])+(?:'|$)|`[^`]*(?:`|$))/,null,"\"'"]],[["com",/^(?:\/\/[^\n\r]*|\/\*[\S\s]*?\*\/)/],["pln",/^(?:[^"'/`]|\/(?![*/]))+/]]),["go"]); 2 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-hs.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t-\r ]+/,null,"\t\n\u000b\u000c\r "],["str",/^"(?:[^\n\f\r"\\]|\\[\S\s])*(?:"|$)/,null,'"'],["str",/^'(?:[^\n\f\r'\\]|\\[^&])'?/,null,"'"],["lit",/^(?:0o[0-7]+|0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)/i,null,"0123456789"]],[["com",/^(?:--+[^\n\f\r]*|{-(?:[^-]|-+[^}-])*-})/],["kwd",/^(?:case|class|data|default|deriving|do|else|if|import|in|infix|infixl|infixr|instance|let|module|newtype|of|then|type|where|_)(?=[^\d'A-Za-z]|$)/, 2 | null],["pln",/^(?:[A-Z][\w']*\.)*[A-Za-z][\w']*/],["pun",/^[^\d\t-\r "'A-Za-z]+/]]),["hs"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-lisp.js: -------------------------------------------------------------------------------- 1 | var a=null; 2 | PR.registerLangHandler(PR.createSimpleLexer([["opn",/^\(+/,a,"("],["clo",/^\)+/,a,")"],["com",/^;[^\n\r]*/,a,";"],["pln",/^[\t\n\r \xa0]+/,a,"\t\n\r \u00a0"],["str",/^"(?:[^"\\]|\\[\S\s])*(?:"|$)/,a,'"']],[["kwd",/^(?:block|c[ad]+r|catch|con[ds]|def(?:ine|un)|do|eq|eql|equal|equalp|eval-when|flet|format|go|if|labels|lambda|let|load-time-value|locally|macrolet|multiple-value-call|nil|progn|progv|quote|require|return-from|setq|symbol-macrolet|t|tagbody|the|throw|unwind)\b/,a], 3 | ["lit",/^[+-]?(?:[#0]x[\da-f]+|\d+\/\d+|(?:\.\d+|\d+(?:\.\d*)?)(?:[de][+-]?\d+)?)/i],["lit",/^'(?:-*(?:\w|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?)?/],["pln",/^-*(?:[_a-z]|\\[!-~])(?:[\w-]*|\\[!-~])[!=?]?/i],["pun",/^[^\w\t\n\r "'-);\\\xa0]+/]]),["cl","el","lisp","lsp","scm","ss","rkt"]); 4 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-lua.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$))/,null,"\"'"]],[["com",/^--(?:\[(=*)\[[\S\s]*?(?:]\1]|$)|[^\n\r]*)/],["str",/^\[(=*)\[[\S\s]*?(?:]\1]|$)/],["kwd",/^(?:and|break|do|else|elseif|end|false|for|function|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i], 2 | ["pln",/^[_a-z]\w*/i],["pun",/^[^\w\t\n\r \xa0][^\w\t\n\r "'+=\xa0-]*/]]),["lua"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-ml.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["com",/^#(?:if[\t\n\r \xa0]+(?:[$_a-z][\w']*|``[^\t\n\r`]*(?:``|$))|else|endif|light)/i,null,"#"],["str",/^(?:"(?:[^"\\]|\\[\S\s])*(?:"|$)|'(?:[^'\\]|\\[\S\s])(?:'|$))/,null,"\"'"]],[["com",/^(?:\/\/[^\n\r]*|\(\*[\S\s]*?\*\))/],["kwd",/^(?:abstract|and|as|assert|begin|class|default|delegate|do|done|downcast|downto|elif|else|end|exception|extern|false|finally|for|fun|function|if|in|inherit|inline|interface|internal|lazy|let|match|member|module|mutable|namespace|new|null|of|open|or|override|private|public|rec|return|static|struct|then|to|true|try|type|upcast|use|val|void|when|while|with|yield|asr|land|lor|lsl|lsr|lxor|mod|sig|atomic|break|checked|component|const|constraint|constructor|continue|eager|event|external|fixed|functor|global|include|method|mixin|object|parallel|process|protected|pure|sealed|trait|virtual|volatile)\b/], 2 | ["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^(?:[_a-z][\w']*[!#?]?|``[^\t\n\r`]*(?:``|$))/i],["pun",/^[^\w\t\n\r "'\xa0]+/]]),["fs","ml"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-n.js: -------------------------------------------------------------------------------- 1 | var a=null; 2 | PR.registerLangHandler(PR.createSimpleLexer([["str",/^(?:'(?:[^\n\r'\\]|\\.)*'|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,a,'"'],["com",/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\n\r]*)/,a,"#"],["pln",/^\s+/,a," \r\n\t\u00a0"]],[["str",/^@"(?:[^"]|"")*(?:"|$)/,a],["str",/^<#[^#>]*(?:#>|$)/,a],["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,a],["com",/^\/\/[^\n\r]*/,a],["com",/^\/\*[\S\s]*?(?:\*\/|$)/, 3 | a],["kwd",/^(?:abstract|and|as|base|catch|class|def|delegate|enum|event|extern|false|finally|fun|implements|interface|internal|is|macro|match|matches|module|mutable|namespace|new|null|out|override|params|partial|private|protected|public|ref|sealed|static|struct|syntax|this|throw|true|try|type|typeof|using|variant|virtual|volatile|when|where|with|assert|assert2|async|break|checked|continue|do|else|ensures|for|foreach|if|late|lock|new|nolate|otherwise|regexp|repeat|requires|return|surroundwith|unchecked|unless|using|while|yield)\b/, 4 | a],["typ",/^(?:array|bool|byte|char|decimal|double|float|int|list|long|object|sbyte|short|string|ulong|uint|ufloat|ulong|ushort|void)\b/,a],["lit",/^@[$_a-z][\w$@]*/i,a],["typ",/^@[A-Z]+[a-z][\w$@]*/,a],["pln",/^'?[$_a-z][\w$@]*/i,a],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,a,"0123456789"],["pun",/^.[^\s\w"-$'./@`]*/,a]]),["n","nemerle"]); 5 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-proto.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.sourceDecorator({keywords:"bytes,default,double,enum,extend,extensions,false,group,import,max,message,option,optional,package,repeated,required,returns,rpc,service,syntax,to,true",types:/^(bool|(double|s?fixed|[su]?int)(32|64)|float|string)\b/,cStyleComments:!0}),["proto"]); 2 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-scala.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["str",/^"(?:""(?:""?(?!")|[^"\\]|\\.)*"{0,3}|(?:[^\n\r"\\]|\\.)*"?)/,null,'"'],["lit",/^`(?:[^\n\r\\`]|\\.)*`?/,null,"`"],["pun",/^[!#%&(--:-@[-^{-~]+/,null,"!#%&()*+,-:;<=>?@[\\]^{|}~"]],[["str",/^'(?:[^\n\r'\\]|\\(?:'|[^\n\r']+))'/],["lit",/^'[$A-Z_a-z][\w$]*(?![\w$'])/],["kwd",/^(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|object|override|package|private|protected|requires|return|sealed|super|throw|trait|try|type|val|var|while|with|yield)\b/], 2 | ["lit",/^(?:true|false|null|this)\b/],["lit",/^(?:0(?:[0-7]+|x[\da-f]+)l?|(?:0|[1-9]\d*)(?:(?:\.\d+)?(?:e[+-]?\d+)?f?|l?)|\\.\d+(?:e[+-]?\d+)?f?)/i],["typ",/^[$_]*[A-Z][\d$A-Z_]*[a-z][\w$]*/],["pln",/^[$A-Z_a-z][\w$]*/],["com",/^\/(?:\/.*|\*(?:\/|\**[^*/])*(?:\*+\/?)?)/],["pun",/^(?:\.+|\/)/]]),["scala"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-sql.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["str",/^(?:"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')/,null,"\"'"]],[["com",/^(?:--[^\n\r]*|\/\*[\S\s]*?(?:\*\/|$))/],["kwd",/^(?:add|all|alter|and|any|apply|as|asc|authorization|backup|begin|between|break|browse|bulk|by|cascade|case|check|checkpoint|close|clustered|coalesce|collate|column|commit|compute|constraint|contains|containstable|continue|convert|create|cross|current|current_date|current_time|current_timestamp|current_user|cursor|database|dbcc|deallocate|declare|default|delete|deny|desc|disk|distinct|distributed|double|drop|dummy|dump|else|end|errlvl|escape|except|exec|execute|exists|exit|fetch|file|fillfactor|following|for|foreign|freetext|freetexttable|from|full|function|goto|grant|group|having|holdlock|identity|identitycol|identity_insert|if|in|index|inner|insert|intersect|into|is|join|key|kill|left|like|lineno|load|match|merge|national|nocheck|nonclustered|not|null|nullif|of|off|offsets|on|open|opendatasource|openquery|openrowset|openxml|option|or|order|outer|over|percent|plan|preceding|precision|primary|print|proc|procedure|public|raiserror|read|readtext|reconfigure|references|replication|restore|restrict|return|revoke|right|rollback|rowcount|rowguidcol|rows?|rule|save|schema|select|session_user|set|setuser|shutdown|some|statistics|system_user|table|textsize|then|to|top|tran|transaction|trigger|truncate|tsequal|unbounded|union|unique|update|updatetext|use|user|using|values|varying|view|waitfor|when|where|while|with|writetext)(?=[^\w-]|$)/i, 2 | null],["lit",/^[+-]?(?:0x[\da-f]+|(?:\.\d+|\d+(?:\.\d*)?)(?:e[+-]?\d+)?)/i],["pln",/^[_a-z][\w-]*/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'+\xa0-]*/]]),["sql"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-tex.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"],["com",/^%[^\n\r]*/,null,"%"]],[["kwd",/^\\[@-Za-z]+/],["kwd",/^\\./],["typ",/^[$&]/],["lit",/[+-]?(?:\.\d+|\d+(?:\.\d*)?)(cm|em|ex|in|pc|pt|bp|mm)/i],["pun",/^[()=[\]{}]+/]]),["latex","tex"]); 2 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-vb.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0\u2028\u2029]+/,null,"\t\n\r \u00a0\u2028\u2029"],["str",/^(?:["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})(?:["\u201c\u201d]c|$)|["\u201c\u201d](?:[^"\u201c\u201d]|["\u201c\u201d]{2})*(?:["\u201c\u201d]|$))/i,null,'"\u201c\u201d'],["com",/^['\u2018\u2019](?:_(?:\r\n?|[^\r]?)|[^\n\r_\u2028\u2029])*/,null,"'\u2018\u2019"]],[["kwd",/^(?:addhandler|addressof|alias|and|andalso|ansi|as|assembly|auto|boolean|byref|byte|byval|call|case|catch|cbool|cbyte|cchar|cdate|cdbl|cdec|char|cint|class|clng|cobj|const|cshort|csng|cstr|ctype|date|decimal|declare|default|delegate|dim|directcast|do|double|each|else|elseif|end|endif|enum|erase|error|event|exit|finally|for|friend|function|get|gettype|gosub|goto|handles|if|implements|imports|in|inherits|integer|interface|is|let|lib|like|long|loop|me|mod|module|mustinherit|mustoverride|mybase|myclass|namespace|new|next|not|notinheritable|notoverridable|object|on|option|optional|or|orelse|overloads|overridable|overrides|paramarray|preserve|private|property|protected|public|raiseevent|readonly|redim|removehandler|resume|return|select|set|shadows|shared|short|single|static|step|stop|string|structure|sub|synclock|then|throw|to|try|typeof|unicode|until|variant|wend|when|while|with|withevents|writeonly|xor|endif|gosub|let|variant|wend)\b/i, 2 | null],["com",/^rem.*/i],["lit",/^(?:true\b|false\b|nothing\b|\d+(?:e[+-]?\d+[dfr]?|[dfilrs])?|(?:&h[\da-f]+|&o[0-7]+)[ils]?|\d*\.\d+(?:e[+-]?\d+)?[dfr]?|#\s+(?:\d+[/-]\d+[/-]\d+(?:\s+\d+:\d+(?::\d+)?(\s*(?:am|pm))?)?|\d+:\d+(?::\d+)?(\s*(?:am|pm))?)\s+#)/i],["pln",/^(?:(?:[a-z]|_\w)\w*|\[(?:[a-z]|_\w)\w*])/i],["pun",/^[^\w\t\n\r "'[\]\xa0\u2018\u2019\u201c\u201d\u2028\u2029]+/],["pun",/^(?:\[|])/]]),["vb","vbs"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-vhdl.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\r \xa0]+/,null,"\t\n\r \u00a0"]],[["str",/^(?:[box]?"(?:[^"]|"")*"|'.')/i],["com",/^--[^\n\r]*/],["kwd",/^(?:abs|access|after|alias|all|and|architecture|array|assert|attribute|begin|block|body|buffer|bus|case|component|configuration|constant|disconnect|downto|else|elsif|end|entity|exit|file|for|function|generate|generic|group|guarded|if|impure|in|inertial|inout|is|label|library|linkage|literal|loop|map|mod|nand|new|next|nor|not|null|of|on|open|or|others|out|package|port|postponed|procedure|process|pure|range|record|register|reject|rem|report|return|rol|ror|select|severity|shared|signal|sla|sll|sra|srl|subtype|then|to|transport|type|unaffected|units|until|use|variable|wait|when|while|with|xnor|xor)(?=[^\w-]|$)/i, 2 | null],["typ",/^(?:bit|bit_vector|character|boolean|integer|real|time|string|severity_level|positive|natural|signed|unsigned|line|text|std_u?logic(?:_vector)?)(?=[^\w-]|$)/i,null],["typ",/^'(?:active|ascending|base|delayed|driving|driving_value|event|high|image|instance_name|last_active|last_event|last_value|left|leftof|length|low|path_name|pos|pred|quiet|range|reverse_range|right|rightof|simple_name|stable|succ|transaction|val|value)(?=[^\w-]|$)/i,null],["lit",/^\d+(?:_\d+)*(?:#[\w.\\]+#(?:[+-]?\d+(?:_\d+)*)?|(?:\.\d+(?:_\d+)*)?(?:e[+-]?\d+(?:_\d+)*)?)/i], 3 | ["pln",/^(?:[a-z]\w*|\\[^\\]*\\)/i],["pun",/^[^\w\t\n\r "'\xa0][^\w\t\n\r "'\xa0-]*/]]),["vhdl","vhd"]); 4 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-wiki.js: -------------------------------------------------------------------------------- 1 | PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\d\t a-gi-z\xa0]+/,null,"\t \u00a0abcdefgijklmnopqrstuvwxyz0123456789"],["pun",/^[*=[\]^~]+/,null,"=*~^[]"]],[["lang-wiki.meta",/(?:^^|\r\n?|\n)(#[a-z]+)\b/],["lit",/^[A-Z][a-z][\da-z]+[A-Z][a-z][^\W_]+\b/],["lang-",/^{{{([\S\s]+?)}}}/],["lang-",/^`([^\n\r`]+)`/],["str",/^https?:\/\/[^\s#/?]*(?:\/[^\s#?]*)?(?:\?[^\s#]*)?(?:#\S*)?/i],["pln",/^(?:\r\n|[\S\s])[^\n\r#*=A-[^`h{~]*/]]),["wiki"]); 2 | PR.registerLangHandler(PR.createSimpleLexer([["kwd",/^#[a-z]+/i,null,"#"]],[]),["wiki.meta"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/lang-yaml.js: -------------------------------------------------------------------------------- 1 | var a=null; 2 | PR.registerLangHandler(PR.createSimpleLexer([["pun",/^[:>?|]+/,a,":|>?"],["dec",/^%(?:YAML|TAG)[^\n\r#]+/,a,"%"],["typ",/^&\S+/,a,"&"],["typ",/^!\S*/,a,"!"],["str",/^"(?:[^"\\]|\\.)*(?:"|$)/,a,'"'],["str",/^'(?:[^']|'')*(?:'|$)/,a,"'"],["com",/^#[^\n\r]*/,a,"#"],["pln",/^\s+/,a," \t\r\n"]],[["dec",/^(?:---|\.\.\.)(?:[\n\r]|$)/],["pun",/^-/],["kwd",/^\w+:[\n\r ]/],["pln",/^\w+/]]),["yaml","yml"]); 3 | -------------------------------------------------------------------------------- /home/google-code-prettify/prettify.css: -------------------------------------------------------------------------------- 1 | .com { color: #93a1a1; } 2 | .lit { color: #195f91; } 3 | .pun, .opn, .clo { color: #93a1a1; } 4 | .fun { color: #dc322f; } 5 | .str, .atv { color: #D14; } 6 | .kwd, .linenums .tag { color: #1e347b; } 7 | .typ, .atn, .dec, .var { color: teal; } 8 | .pln { color: #48484c; } 9 | 10 | .prettyprint { 11 | padding: 8px; 12 | background-color: #f7f7f9; 13 | border: 1px solid #e1e1e8; 14 | } 15 | .prettyprint.linenums { 16 | -webkit-box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 17 | -moz-box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 18 | box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 19 | } 20 | 21 | /* Specify class=linenums on a pre to get line numbering */ 22 | ol.linenums { 23 | margin: 0 0 0 33px; /* IE indents via margin-left */ 24 | } 25 | ol.linenums li { 26 | padding-left: 12px; 27 | color: #bebec5; 28 | line-height: 18px; 29 | text-shadow: 0 1px 0 #fff; 30 | } -------------------------------------------------------------------------------- /home/greet.php: -------------------------------------------------------------------------------- 1 | $name, 48 | "salutation" => $salutation, 49 | "greeting" => $greeting ); 50 | $json = json_encode($data); 51 | header("Content-type: text/javascript"); 52 | if ($callback) 53 | echo $callback .' (' . $json . ');'; 54 | else 55 | echo $json; 56 | ?> -------------------------------------------------------------------------------- /home/img/AngularJS-large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/AngularJS-large.png -------------------------------------------------------------------------------- /home/img/AngularJS-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/AngularJS-small.png -------------------------------------------------------------------------------- /home/img/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /home/img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /home/img/google-black.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/google-black.png -------------------------------------------------------------------------------- /home/img/google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/google.png -------------------------------------------------------------------------------- /home/img/video-over.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/video-over.png -------------------------------------------------------------------------------- /home/img/video.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/home/img/video.png -------------------------------------------------------------------------------- /home/index.yaml: -------------------------------------------------------------------------------- 1 | indexes: 2 | 3 | # AUTOGENERATED 4 | 5 | # This index.yaml is automatically updated whenever the dev_appserver 6 | # detects that a new type of query is run. If you want to manage the 7 | # index.yaml file manually, remove the above marker line (the line 8 | # saying "# AUTOGENERATED"). If you want to manage some indexes 9 | # manually, move them above the marker line. The index.yaml file is 10 | # automatically uploaded to the admin console when you next deploy 11 | # your application using appcfg.py. 12 | 13 | -------------------------------------------------------------------------------- /home/misc/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "angularjs.org-misc-tools", 3 | "version": "0.0.0", 4 | "dependencies" : { 5 | "q" : "*" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /i18n/README.md: -------------------------------------------------------------------------------- 1 | # i18n directory overview: 2 | 3 | - closure/ - closure files we use for ruleset generation 4 | - locale/ - angular's locale ruleset files 5 | - src/ - source files 6 | - spec/ - spec files for stuff in src directory 7 | - generate.sh - runs src scripts on closure dir and stores output in locale dir 8 | - update-closure.sh - downloads the latest version of closure files from public svn repo 9 | 10 | The closure files (maintained by Shanjian Li (shanjian)) change very rarely, so we don't need to 11 | regenerate locale files very often. 12 | 13 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_cs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 8 | 13 | 14 | 15 |
16 | date: {{input | date:"medium"}}
17 | date: {{input | date:"longDate"}}
18 | number: {{input | number}}
19 | currency: {{input | currency }} 20 | 21 | 22 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_de.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 8 | 13 | 14 | 15 |
16 | date: {{input | date:"medium"}}
17 | date: {{input | date:"longDate"}}
18 | number: {{input | number}}
19 | currency: {{input | currency }} 20 | 21 | 22 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_en.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 10 | 19 | 20 | 21 |

Datetime/Number/Currency filters demo:

22 |
23 | date(medium): {{input | date:"medium"}}
24 | date(longDate): {{input | date:"longDate"}}
25 | number: {{input | number}}
26 | currency: {{input | currency }} 27 |
28 |

Pluralization demo:

29 |
30 | 34 | 35 |
36 |

Pluralization demo with offsets:

37 | Name of person1:
38 | Name of person2:
39 |
40 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_es.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 8 | 13 | 14 | 15 |
16 | date: {{input | date:"medium"}}
17 | date: {{input | date:"longDate"}}
18 | number: {{input | number}}
19 | currency: {{input | currency }} 20 | 21 | 22 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_sk.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 8 | 14 | 15 | 16 |
17 | date: {{input | date:"medium"}}
18 | date: {{input | date:"longDate"}}
19 | number: {{input | number}}
20 | currency: {{input | currency }} 21 |
22 |
23 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /i18n/e2e/localeTest_zh.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | locale test 6 | 7 | 8 | 17 | 18 | 19 |

Datetime/Number/Currency filters demo:

20 |
21 | date(medium): {{input | date:"medium"}}
22 | date(longDate): {{input | date:"longDate"}}
23 | number: {{input | number}}
24 | currency: {{input | currency }} 25 |
26 |

Pluralization demo:

27 |
28 | 30 | 31 |
32 |

Pluralization demo with offsets:

33 | Name of person1:
34 | Name of person2:
35 |
36 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /i18n/e2e/runner.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | <angular/> Docs Scenario Runner 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /i18n/generate.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | BASE_DIR=`dirname $0` 4 | cd $BASE_DIR 5 | 6 | 7 | /usr/bin/env jasmine-node spec/ --noColor && node src/closureSlurper.js 8 | -------------------------------------------------------------------------------- /i18n/run-tests.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | PARENT_DIR="$(dirname "$0")" 5 | jasmine-node "$PARENT_DIR"/spec/ 6 | -------------------------------------------------------------------------------- /i18n/spec/utilSpec.js: -------------------------------------------------------------------------------- 1 | var util = require('../src/util.js'); 2 | 3 | describe('findLocaleId', function() { 4 | it('should find localeId', function() { 5 | expect(util.findLocaleId('', 'num')).toBeUndefined(); 6 | expect(util.findLocaleId('aa', 'datetime')).toBeUndefined(); 7 | expect(util.findLocaleId('aa', 'randomType')).toBeUndefined(); 8 | expect(util.findLocaleId('NumberFormatSymbols_en', 'datetime')).toBeUndefined(); 9 | expect(util.findLocaleId('DateTimeSymbols_en', 'num')).toBeUndefined(); 10 | 11 | expect(util.findLocaleId('DateTimeSymbols_en', 'datetime')).toBe('en'); 12 | expect(util.findLocaleId('NumberFormatSymbols_en_US', 'num')).toBe('en_US'); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /i18n/src/parser.js: -------------------------------------------------------------------------------- 1 | /** 2 | * A simple parser to parse a number format into a pattern object 3 | */ 4 | 5 | exports.parsePattern = parsePattern; 6 | 7 | var PATTERN_SEP = ';', 8 | DECIMAL_SEP = '.', 9 | GROUP_SEP = ',', 10 | ZERO = '0', 11 | DIGIT = '#'; 12 | 13 | /** 14 | * main funciton for parser 15 | * @param str {string} pattern to be parsed (e.g. #,##0.###). 16 | */ 17 | function parsePattern(pattern) { 18 | var p = { 19 | minInt: 1, 20 | minFrac: 0, 21 | macFrac: 0, 22 | posPre: '', 23 | posSuf: '', 24 | negPre: '', 25 | negSuf: '', 26 | gSize: 0, 27 | lgSize: 0 28 | }; 29 | 30 | var parts = pattern.split(PATTERN_SEP), 31 | positive = parts[0], 32 | negative = parts[1]; 33 | 34 | var parts = positive.split(DECIMAL_SEP), 35 | integer = parts[0], 36 | fraction = parts[1]; 37 | 38 | p.posPre = integer.substr(0, integer.indexOf(DIGIT)); 39 | 40 | for (var i = 0; i < fraction.length; i++) { 41 | var ch = fraction.charAt(i); 42 | if (ch == ZERO) p.minFrac = p.maxFrac = i + 1; 43 | else if (ch == DIGIT) p.maxFrac = i + 1; 44 | else p.posSuf += ch; 45 | } 46 | 47 | var groups = integer.split(GROUP_SEP); 48 | p.gSize = groups[1] ? groups[1].length : 0; 49 | p.lgSize = (groups[2] || groups[1]) ? (groups[2] || groups[1]).length : 0; 50 | 51 | if (negative) { 52 | var trunkLen = positive.length - p.posPre.length - p.posSuf.length, 53 | pos = negative.indexOf(DIGIT); 54 | 55 | p.negPre = negative.substr(0, pos).replace(/\'/g, ''); 56 | p.negSuf = negative.substr(pos + trunkLen).replace(/\'/g, ''); 57 | } else { 58 | // hardcoded '-' sign is fine as all locale use '-' as MINUS_SIGN. (\u2212 is the same as '-') 59 | p.negPre = p.posPre + '-'; 60 | p.negSuf = p.posSuf; 61 | } 62 | 63 | return p; 64 | } 65 | -------------------------------------------------------------------------------- /i18n/src/util.js: -------------------------------------------------------------------------------- 1 | exports.findLocaleId = function findLocaleId(str, type) { 2 | if (type === 'num') { 3 | return (str.match(/^NumberFormatSymbols_(.+)$/) || [])[1]; 4 | } else if (type == 'datetime') { 5 | return (str.match(/^DateTimeSymbols_(.+)$/) || [])[1]; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /i18n/update-closure.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e # Exit on error. 4 | 5 | BASE_DIR=`dirname $0` 6 | cd $BASE_DIR 7 | 8 | set -x # Trace commands as they're executed. 9 | 10 | curl http://closure-library.googlecode.com/svn/trunk/closure/goog/i18n/currency.js > closure/currencySymbols.js 11 | curl http://closure-library.googlecode.com/svn/trunk/closure/goog/i18n/datetimesymbols.js > closure/datetimeSymbols.js 12 | curl http://closure-library.googlecode.com/svn/trunk/closure/goog/i18n/datetimesymbolsext.js > closure/datetimeSymbolsExt.js 13 | curl http://closure-library.googlecode.com/svn/trunk/closure/goog/i18n/numberformatsymbols.js > closure/numberSymbols.js 14 | curl http://closure-library.googlecode.com/svn/trunk/closure/goog/i18n/pluralrules.js > closure/pluralRules.js 15 | -------------------------------------------------------------------------------- /images/css/arrow_left.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/css/arrow_left.gif -------------------------------------------------------------------------------- /images/css/arrow_right.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/css/arrow_right.gif -------------------------------------------------------------------------------- /images/css/indicator-wait.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/css/indicator-wait.png -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/image1.png -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/image2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/image2.png -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/image4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/image4.png -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/image8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/image8.png -------------------------------------------------------------------------------- /images/docs/Diagrams.graffle/image9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/Diagrams.graffle/image9.png -------------------------------------------------------------------------------- /images/docs/guide/about_view.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/about_view.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/guide/about_view.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/about_view.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/guide/about_view.graffle/image3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/about_view.graffle/image3.png -------------------------------------------------------------------------------- /images/docs/guide/concepts.graffle/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/concepts.graffle/image1.png -------------------------------------------------------------------------------- /images/docs/guide/concepts.graffle/image4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/concepts.graffle/image4.png -------------------------------------------------------------------------------- /images/docs/guide/concepts.graffle/image5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/concepts.graffle/image5.png -------------------------------------------------------------------------------- /images/docs/guide/simple_scope.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/simple_scope.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/guide/simple_scope.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/simple_scope.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/guide/simple_scope.graffle/image7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/guide/simple_scope.graffle/image7.png -------------------------------------------------------------------------------- /images/docs/tutorial/simple_scope.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/simple_scope.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/simple_scope.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/simple_scope.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/simple_scope.graffle/image7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/simple_scope.graffle/image7.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_02.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_02.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_02.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_02.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_02.graffle/image11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_02.graffle/image11.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_03.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_03.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_03.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_03.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_03.graffle/image13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_03.graffle/image13.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_04.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_04.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_04.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_04.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_04.graffle/image15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_04.graffle/image15.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_07.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_07.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_07.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_07.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_07.graffle/image9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_07.graffle/image9.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_08-09.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_08-09.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_08-09.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_08-09.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_08-09.graffle/image10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_08-09.graffle/image10.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_10-11.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_10-11.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_10-11.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_10-11.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_10-11.graffle/image10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_10-11.graffle/image10.png -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_proto.graffle/QuickLook/Preview.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_proto.graffle/QuickLook/Preview.pdf -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_proto.graffle/QuickLook/Thumbnail.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_proto.graffle/QuickLook/Thumbnail.tiff -------------------------------------------------------------------------------- /images/docs/tutorial/tutorial_proto.graffle/image7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/docs/tutorial/tutorial_proto.graffle/image7.png -------------------------------------------------------------------------------- /images/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/favicon.ico -------------------------------------------------------------------------------- /images/logo/AngularJS-Shield.exports/AngularJS-Shield-huge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS-Shield.exports/AngularJS-Shield-huge.png -------------------------------------------------------------------------------- /images/logo/AngularJS-Shield.exports/AngularJS-Shield-large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS-Shield.exports/AngularJS-Shield-large.png -------------------------------------------------------------------------------- /images/logo/AngularJS-Shield.exports/AngularJS-Shield-medium.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS-Shield.exports/AngularJS-Shield-medium.png -------------------------------------------------------------------------------- /images/logo/AngularJS-Shield.exports/AngularJS-Shield-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS-Shield.exports/AngularJS-Shield-small.png -------------------------------------------------------------------------------- /images/logo/AngularJS-Shield.exports/AngularJS-Shield.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS-Shield.exports/AngularJS-Shield.pdf -------------------------------------------------------------------------------- /images/logo/AngularJS.exports/AngularJS-huge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.exports/AngularJS-huge.png -------------------------------------------------------------------------------- /images/logo/AngularJS.exports/AngularJS-large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.exports/AngularJS-large.png -------------------------------------------------------------------------------- /images/logo/AngularJS.exports/AngularJS-medium.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.exports/AngularJS-medium.png -------------------------------------------------------------------------------- /images/logo/AngularJS.exports/AngularJS-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.exports/AngularJS-small.png -------------------------------------------------------------------------------- /images/logo/AngularJS.exports/AngularJS.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.exports/AngularJS.pdf -------------------------------------------------------------------------------- /images/logo/AngularJS.graffle/data.plist: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.graffle/data.plist -------------------------------------------------------------------------------- /images/logo/AngularJS.graffle/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.graffle/image1.png -------------------------------------------------------------------------------- /images/logo/AngularJS.graffle/image2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/images/logo/AngularJS.graffle/image2.png -------------------------------------------------------------------------------- /init-app.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # Script to initialize angular app 4 | set -e 5 | 6 | # @log startup time 7 | START_SERVER_TEIM=$(date +%s) 8 | 9 | rm -rf app 10 | 11 | # copy doc directory 12 | if [ "$APP_ENV" = "development" ]; then 13 | # save symlinks 14 | ln -s build/docs app 15 | else 16 | # resolve symlinks 17 | cp -Lr build/docs app 18 | fi 19 | 20 | # copy javascript files 21 | cp build/*.js app/ 22 | 23 | # copy img, javascript and other files for home page 24 | cp -r home app/home 25 | 26 | # copy home page 27 | cp docs/src/templates/home.html app/ 28 | cd app 29 | 30 | cat > "main.js" << EOF 31 | var express = require('express'); 32 | var connect = require('connect'); 33 | var app = express(); 34 | app.use(connect.compress()); 35 | console.log(__dirname); 36 | app.get('^(/|home\.html )$', function(req, res) { 37 | res.sendfile('home.html'); 38 | }); 39 | app.use(express.static(__dirname + '/')); 40 | // HTML5 URL Support 41 | app.get('^\/?(guide|api|cookbook|misc|tutorial|ui)(/)?*$', function(req, res) { 42 | res.sendfile('index.html'); 43 | }); 44 | var port = process.env.PORT || 8000; 45 | console.log('SERVER RUN ON PORT: ', port); 46 | app.listen(port); 47 | EOF 48 | 49 | END_SERVER_TEIM=$(date +%s) 50 | 51 | # @log startup time 52 | echo "SERVER START TIME: $((END_SERVER_TEIM - START_SERVER_TEIM))" 53 | 54 | node main.js 55 | -------------------------------------------------------------------------------- /init-repo.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # Script to initialize angular repo 4 | # - install required node packages 5 | # - install Karma 6 | # - install git hooks 7 | 8 | 9 | node=`which node 2>&1` 10 | if [ $? -ne 0 ]; then 11 | echo "Please install NodeJS." 12 | echo "http://nodejs.org/" 13 | exit 1 14 | fi 15 | 16 | npm=`which npm 2>&1` 17 | if [ $? -ne 0 ]; then 18 | echo "Please install NPM." 19 | fi 20 | 21 | 22 | echo "Installing required npm packages..." 23 | npm install 24 | 25 | karma=`which karma 2>&1` 26 | if [ $? -ne 0 ]; then 27 | echo "Installing Karma..." 28 | npm install -g karma 29 | fi 30 | 31 | echo "Installing git hooks..." 32 | ln -sf ../../validate-commit-msg.js .git/hooks/commit-msg 33 | -------------------------------------------------------------------------------- /karma-e2e.conf.js: -------------------------------------------------------------------------------- 1 | var angularFiles = require(__dirname + '/angularFiles.js'); 2 | 3 | files = [ANGULAR_SCENARIO, ANGULAR_SCENARIO_ADAPTER, 'build/docs/docs-scenario.js']; 4 | 5 | autoWatch = false; 6 | singleRun = true; 7 | logLevel = LOG_INFO; 8 | logColors = true; 9 | browsers = ['Chrome']; 10 | 11 | proxies = { 12 | // angular.js, angular-resource.js, etc 13 | '/angular': 'http://localhost:8000/build/angular', 14 | '/': 'http://localhost:8000/build/docs/' 15 | }; 16 | 17 | junitReporter = { 18 | outputFile: 'test_out/e2e.xml', 19 | suite: 'E2E' 20 | }; 21 | -------------------------------------------------------------------------------- /karma-jqlite.conf.js: -------------------------------------------------------------------------------- 1 | var angularFiles = require(__dirname + '/angularFiles.js'); 2 | 3 | files = angularFiles.mergeFiles(JASMINE, JASMINE_ADAPTER, 'jstd'); 4 | exclude = ['**/*jasmine*/**', '**/*jstd*/**'].concat(angularFiles.files.jstdExclude); 5 | 6 | autoWatch = true; 7 | logLevel = LOG_INFO; 8 | logColors = true; 9 | browsers = ['Chrome']; 10 | 11 | junitReporter = { 12 | outputFile: 'test_out/jqlite.xml', 13 | suite: 'jqLite' 14 | }; 15 | -------------------------------------------------------------------------------- /karma-jquery.conf.js: -------------------------------------------------------------------------------- 1 | var angularFiles = require(__dirname + '/angularFiles.js'); 2 | 3 | files = angularFiles.mergeFiles(JASMINE, JASMINE_ADAPTER, 'jstdJquery'); 4 | exclude = ['**/*jasmine*/**', '**/*jstd*/**'].concat(angularFiles.files.jstdJqueryExclude); 5 | 6 | autoWatch = true; 7 | logLevel = LOG_INFO; 8 | logColors = true; 9 | browsers = ['Chrome']; 10 | 11 | junitReporter = { 12 | outputFile: 'test_out/jquery.xml', 13 | suite: 'jQuery' 14 | }; 15 | -------------------------------------------------------------------------------- /karma-modules.conf.js: -------------------------------------------------------------------------------- 1 | var angularFiles = require(__dirname + '/angularFiles.js'); 2 | 3 | files = angularFiles.mergeFiles(JASMINE, JASMINE_ADAPTER, 'jstdModules', 'angularSrcModules'); 4 | exclude = ['**/*jasmine*/**', '**/*jstd*/**']; 5 | 6 | autoWatch = true; 7 | logLevel = LOG_INFO; 8 | logColors = true; 9 | browsers = ['Chrome']; 10 | 11 | junitReporter = { 12 | outputFile: 'test_out/modules.xml', 13 | suite: 'modules' 14 | }; 15 | -------------------------------------------------------------------------------- /lib/closure-compiler/compiler.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/lib/closure-compiler/compiler.jar -------------------------------------------------------------------------------- /lib/closure-compiler/version.txt: -------------------------------------------------------------------------------- 1 | 20110615 2 | -------------------------------------------------------------------------------- /lib/jquery/version.txt: -------------------------------------------------------------------------------- 1 | 1.8.2 2 | -------------------------------------------------------------------------------- /lib/showdown/index.js: -------------------------------------------------------------------------------- 1 | var fs = require('fs'); 2 | var vm = require('vm'); 3 | 4 | var filename = __dirname + '/showdown-0.9.js'; 5 | var src = fs.readFileSync(filename); 6 | var Showdown = vm.runInThisContext(src + '\nShowdown;', filename); 7 | exports.Showdown = Showdown; 8 | -------------------------------------------------------------------------------- /logs/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /logs/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AngularjsRUS/angular-doc/e072d3cfb47da85ca6932cec15d3810023d687fb/logs/.gitkeep -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "AngularJS", 3 | "version": "0.0.0", 4 | "dependencies": { 5 | "npm": "1.2.x", 6 | "grunt-cli": "0.1.x", 7 | "express": "3.x", 8 | "connect" : "2.x", 9 | "grunt": "0.4.0", 10 | "grunt-contrib-clean": "0.4.0", 11 | "grunt-contrib-compress": "0.4.1", 12 | "grunt-contrib-connect": "0.1.2", 13 | "grunt-contrib-copy": "0.4.1", 14 | "grunt-contrib-uglify": "*", 15 | "jasmine-node": "1.2.3", 16 | "q": "~0.9.2", 17 | "q-fs": "0.1.36", 18 | "qq": "0.3.5", 19 | "shelljs": "0.1.2", 20 | "karma": "0.8.4", 21 | "yaml-js": "0.0.5" 22 | }, 23 | "engines":{ 24 | "node": "0.10.21" 25 | }, 26 | "licenses": [ 27 | { 28 | "type": "MIT", 29 | "url": "https://github.com/angular/angular.js/blob/master/LICENSE" 30 | } 31 | ] 32 | } 33 | -------------------------------------------------------------------------------- /release-commit.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | function catch_errors() { 4 | echo "ERROR. That's life." 5 | exit 1 6 | } 7 | 8 | trap catch_errors ERR 9 | 10 | TMP_FILE='changelog.tmp' 11 | CHANGELOG_FILE='CHANGELOG.md' 12 | 13 | echo "Getting current version..." 14 | VERSION=`./version.js --current` 15 | 16 | echo "Generating changelog..." 17 | ./changelog.js $VERSION $TMP_FILE 18 | 19 | cat $CHANGELOG_FILE >> $TMP_FILE 20 | mv -f $TMP_FILE $CHANGELOG_FILE 21 | 22 | 23 | echo "Updating version..." 24 | ./version.js --remove-snapshot 25 | 26 | echo "CONFIRM TO COMMIT" 27 | read WHATEVER 28 | 29 | 30 | echo "Creating commit..." 31 | git commit version.yaml CHANGELOG.md -m "chore(relase): cutting the v$VERSION release" 32 | 33 | echo "Creating tag..." 34 | git tag "v$VERSION" 35 | -------------------------------------------------------------------------------- /scripts/e2e-test.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | REM Windows script for running e2e tests 4 | REM You have to run server and capture some browser first 5 | REM 6 | REM Requirements: 7 | REM - NodeJS (http://nodejs.org/) 8 | REM - Karma (npm install -g karma) 9 | 10 | set BASE_DIR=%~dp0 11 | karma start "%BASE_DIR%\..\config\karma-e2e.conf.js" %* 12 | -------------------------------------------------------------------------------- /scripts/e2e-test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | BASE_DIR=`dirname $0` 4 | 5 | echo "" 6 | echo "Starting Karma Server (http://karma-runner.github.io)" 7 | echo "-------------------------------------------------------------------" 8 | 9 | karma start $BASE_DIR/../config/karma-e2e.conf.js $* 10 | -------------------------------------------------------------------------------- /scripts/test.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | REM Windows script for running unit tests 4 | REM You have to run server and capture some browser first 5 | REM 6 | REM Requirements: 7 | REM - NodeJS (http://nodejs.org/) 8 | REM - Karma (npm install -g karma) 9 | 10 | set BASE_DIR=%~dp0 11 | karma start "%BASE_DIR%\..\config\karma.conf.js" %* 12 | -------------------------------------------------------------------------------- /scripts/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | BASE_DIR=`dirname $0` 4 | 5 | echo "" 6 | echo "Starting Karma Server (http://karma-runner.github.io)" 7 | echo "-------------------------------------------------------------------" 8 | 9 | karma start $BASE_DIR/../config/karma.conf.js $* 10 | -------------------------------------------------------------------------------- /scripts/watchr.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env watchr 2 | 3 | # config file for watchr http://github.com/mynyml/watchr 4 | # install: gem install watchr 5 | # run: watch watchr.rb 6 | # note: make sure that you have jstd server running (server.sh) and a browser captured 7 | 8 | log_file = File.expand_path(File.dirname(__FILE__) + '/../logs/jstd.log') 9 | 10 | `cd ..` 11 | `touch #{log_file}` 12 | 13 | puts "String watchr... log file: #{log_file}" 14 | 15 | watch( '(app/js|test/unit)' ) do 16 | `echo "\n\ntest run started @ \`date\`" > #{log_file}` 17 | `scripts/test.sh &> #{log_file}` 18 | end 19 | 20 | -------------------------------------------------------------------------------- /src/angular.prefix: -------------------------------------------------------------------------------- 1 | /** 2 | * @license AngularJS v"NG_VERSION_FULL" 3 | * (c) 2010-2012 Google, Inc. http://angularjs.org 4 | * License: MIT 5 | */ 6 | (function(window, document, undefined) { 7 | -------------------------------------------------------------------------------- /src/angular.suffix: -------------------------------------------------------------------------------- 1 | //try to bind to jquery now so that one can write angular.element().read() 2 | //but we will rebind on bootstrap again. 3 | bindJQuery(); 4 | 5 | publishExternalAPI(angular); 6 | 7 | jqLite(document).ready(function() { 8 | angularInit(document, bootstrap); 9 | }); 10 | 11 | })(window, document); 12 | -------------------------------------------------------------------------------- /src/apis.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | 4 | /** 5 | * Computes a hash of an 'obj'. 6 | * Hash of a: 7 | * string is string 8 | * number is number as string 9 | * object is either result of calling $$hashKey function on the object or uniquely generated id, 10 | * that is also assigned to the $$hashKey property of the object. 11 | * 12 | * @param obj 13 | * @returns {string} hash string such that the same input will have the same hash string. 14 | * The resulting string key is in 'type:hashKey' format. 15 | */ 16 | function hashKey(obj) { 17 | var objType = typeof obj, 18 | key; 19 | 20 | if (objType == 'object' && obj !== null) { 21 | if (typeof (key = obj.$$hashKey) == 'function') { 22 | // must invoke on object to keep the right this 23 | key = obj.$$hashKey(); 24 | } else if (key === undefined) { 25 | key = obj.$$hashKey = nextUid(); 26 | } 27 | } else { 28 | key = obj; 29 | } 30 | 31 | return objType + ':' + key; 32 | } 33 | 34 | /** 35 | * HashMap which can use objects as keys 36 | */ 37 | function HashMap(array){ 38 | forEach(array, this.put, this); 39 | } 40 | HashMap.prototype = { 41 | /** 42 | * Store key value pair 43 | * @param key key to store can be any type 44 | * @param value value to store can be any type 45 | */ 46 | put: function(key, value) { 47 | this[hashKey(key)] = value; 48 | }, 49 | 50 | /** 51 | * @param key 52 | * @returns the value for the key 53 | */ 54 | get: function(key) { 55 | return this[hashKey(key)]; 56 | }, 57 | 58 | /** 59 | * Remove the key/value pair 60 | * @param key 61 | */ 62 | remove: function(key) { 63 | var value = this[key = hashKey(key)]; 64 | delete this[key]; 65 | return value; 66 | } 67 | }; 68 | -------------------------------------------------------------------------------- /src/bootstrap/google-prettify/prettify.css: -------------------------------------------------------------------------------- 1 | .com { color: #93a1a1; } 2 | .lit { color: #195f91; } 3 | .pun, .opn, .clo { color: #93a1a1; } 4 | .fun { color: #dc322f; } 5 | .str, .atv { color: #D14; } 6 | .kwd, .linenums .tag { color: #1e347b; } 7 | .typ, .atn, .dec, .var { color: teal; } 8 | .pln { color: #48484c; } 9 | 10 | .prettyprint { 11 | padding: 8px; 12 | background-color: #f7f7f9; 13 | border: 1px solid #e1e1e8; 14 | } 15 | .prettyprint.linenums { 16 | -webkit-box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 17 | -moz-box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 18 | box-shadow: inset 40px 0 0 #fbfbfc, inset 41px 0 0 #ececf0; 19 | } 20 | 21 | /* Specify class=linenums on a pre to get line numbering */ 22 | ol.linenums { 23 | margin: 0 0 0 33px; /* IE indents via margin-left */ 24 | } 25 | ol.linenums li { 26 | padding-left: 12px; 27 | color: #bebec5; 28 | line-height: 18px; 29 | text-shadow: 0 1px 0 #fff; 30 | } -------------------------------------------------------------------------------- /src/loader.prefix: -------------------------------------------------------------------------------- 1 | /** 2 | * @license AngularJS v"NG_VERSION_FULL" 3 | * (c) 2010-2012 Google, Inc. http://angularjs.org 4 | * License: MIT 5 | */ 6 | 'use strict'; 7 | ( 8 | -------------------------------------------------------------------------------- /src/loader.suffix: -------------------------------------------------------------------------------- 1 | )(window); 2 | 3 | /** 4 | * Closure compiler type information 5 | * 6 | * @typedef { { 7 | * requires: !Array., 8 | * invokeQueue: !Array.>, 9 | * 10 | * service: function(string, Function):angular.Module, 11 | * factory: function(string, Function):angular.Module, 12 | * value: function(string, *):angular.Module, 13 | * 14 | * filter: function(string, Function):angular.Module, 15 | * 16 | * init: function(Function):angular.Module 17 | * } } 18 | */ 19 | angular.Module; 20 | 21 | -------------------------------------------------------------------------------- /src/module.prefix: -------------------------------------------------------------------------------- 1 | /** 2 | * @license AngularJS v"NG_VERSION_FULL" 3 | * (c) 2010-2012 Google, Inc. http://angularjs.org 4 | * License: MIT 5 | */ 6 | (function(window, angular, undefined) { 7 | -------------------------------------------------------------------------------- /src/module.suffix: -------------------------------------------------------------------------------- 1 | 2 | })(window, window.angular); 3 | -------------------------------------------------------------------------------- /src/ng/directive/a.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:a 6 | * @restrict E 7 | * 8 | * @description 9 | * Изменяет стандартное поведение html тега A, если атрибут href пустой то действие по умолчанию будет 10 | * отменено. 11 | * 12 | * Смысл этого изменения в том, что бы можно было легко создавать ссылки с директивой 13 | * `ngClick` и при этом не волноваться о перезагрузке страницы или изменении адреса. Пример: 14 | * `Save` 15 | */ 16 | var htmlAnchorDirective = valueFn({ 17 | restrict: 'E', 18 | compile: function(element, attr) { 19 | 20 | if (msie <= 8) { 21 | // превращение link в стилизованную ссылку IE 22 | // но только если она не имеет названия и никуда не ведет, в нашем случае не имеет якоря 23 | if (!attr.href && !attr.name) { 24 | attr.$set('href', ''); 25 | } 26 | 27 | // добавление комментария для якоря, чтобы обойти IE баг, приводящий к сбросу содержания элемента 28 | // к новому содержанию атрибута, если атрибут обновлялся значением, содержащим @ или 29 | // содержал значение с @ 30 | // см. issue #1949 31 | element.append(document.createComment('IE fix')); 32 | } 33 | 34 | return function(scope, element) { 35 | element.bind('click', function(event){ 36 | // если в href не содержится url, то мы никуда не переходим 37 | if (!element.attr('href')) { 38 | event.preventDefault(); 39 | } 40 | }); 41 | } 42 | } 43 | }); 44 | -------------------------------------------------------------------------------- /src/ng/directive/directives.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function ngDirective(directive) { 4 | if (isFunction(directive)) { 5 | directive = { 6 | link: directive 7 | } 8 | } 9 | directive.restrict = directive.restrict || 'AC'; 10 | return valueFn(directive); 11 | } 12 | -------------------------------------------------------------------------------- /src/ng/directive/ngCsp.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:ngCsp 6 | * @priority 1000 7 | * 8 | * @description 9 | * Включает поддержку [CSP (Правила безопасности контента)](https://developer.mozilla.org/en/Security/CSP). 10 | * Эта директива должна быть использована в корневом элементе приложения (обычно это `` элемент или 11 | * другой элемент, {@link ng.directive:ngApp ngApp}). 12 | * 13 | * Если ее включить, производительность шаблонов незначительно пострадает, поэтому не включайте без крайней 14 | * необходимости. 15 | * 16 | * @element html 17 | */ 18 | 19 | var ngCspDirective = ['$sniffer', function($sniffer) { 20 | return { 21 | priority: 1000, 22 | compile: function() { 23 | $sniffer.csp = true; 24 | } 25 | }; 26 | }]; 27 | -------------------------------------------------------------------------------- /src/ng/directive/ngInit.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:ngInit 6 | * 7 | * @description 8 | * Директива `ngInit` выполняет код инициализации перед построением шаблона во время начальной 9 | * инициализации приложения. 10 | * 11 | * @element ANY 12 | * @param {expression} ngInit {@link guide/expression Выражение} для вычисления. 13 | * 14 | * @example 15 | 16 | 17 |
18 | {{greeting}} {{person}}! 19 |
20 |
21 | 22 | it('should check greeting', function() { 23 | expect(binding('greeting')).toBe('Hello'); 24 | expect(binding('person')).toBe('World'); 25 | }); 26 | 27 |
28 | */ 29 | var ngInitDirective = ngDirective({ 30 | compile: function() { 31 | return { 32 | pre: function(scope, element, attrs) { 33 | scope.$eval(attrs.ngInit); 34 | } 35 | } 36 | } 37 | }); 38 | -------------------------------------------------------------------------------- /src/ng/directive/ngNonBindable.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:ngNonBindable 6 | * @priority 1000 7 | * 8 | * @description 9 | * Иногда требуется написать код, который является корректным angular-выражением, но которое должно отображаться как 10 | * есть, без вычисления. Используйте `ngNonBindable` чтобы заставить Angular игнорировать содержимое HTML. 11 | * 12 | * @element ANY 13 | * 14 | * @example 15 | * В этом примере связывание данных (`{{}}`) присутствует в двух местах, но в одном завернуто в `ngNonBindable` и 16 | * не вычисляется. 17 | * 18 | * @example 19 | 20 | 21 |
Normal: {{1 + 2}}
22 |
Ignored: {{1 + 2}}
23 |
24 | 25 | it('should check ng-non-bindable', function() { 26 | expect(using('.doc-example-live').binding('1 + 2')).toBe('3'); 27 | expect(using('.doc-example-live').element('div:last').text()). 28 | toMatch(/1 \+ 2/); 29 | }); 30 | 31 |
32 | */ 33 | var ngNonBindableDirective = ngDirective({ terminal: true, priority: 1000 }); 34 | -------------------------------------------------------------------------------- /src/ng/directive/ngStyle.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:ngStyle 6 | * 7 | * @description 8 | * Директива `ngStyle` позволяет устанавливать CSS стили для элементов HTML в зависимости от условий. 9 | * 10 | * @element ANY 11 | * @param {expression} ngStyle {@link guide/expression Выражение} которое возвращает объект, ключами 12 | * которого выступают имена задаваемых стилей CSS, а значения – это значения задаваемые свойству CSS. 13 | * 14 | * @example 15 | 16 | 17 | 18 | 19 |
20 | Sample Text 21 |
myStyle={{myStyle}}
22 |
23 | 24 | span { 25 | color: black; 26 | } 27 | 28 | 29 | it('should check ng-style', function() { 30 | expect(element('.doc-example-live span').css('color')).toBe('rgb(0, 0, 0)'); 31 | element('.doc-example-live :button[value=set]').click(); 32 | expect(element('.doc-example-live span').css('color')).toBe('rgb(255, 0, 0)'); 33 | element('.doc-example-live :button[value=clear]').click(); 34 | expect(element('.doc-example-live span').css('color')).toBe('rgb(0, 0, 0)'); 35 | }); 36 | 37 |
38 | */ 39 | var ngStyleDirective = ngDirective(function(scope, element, attr) { 40 | scope.$watch(attr.ngStyle, function ngStyleWatchAction(newStyles, oldStyles) { 41 | if (oldStyles && (newStyles !== oldStyles)) { 42 | forEach(oldStyles, function(val, style) { element.css(style, '');}); 43 | } 44 | if (newStyles) element.css(newStyles); 45 | }, true); 46 | }); 47 | -------------------------------------------------------------------------------- /src/ng/directive/ngTransclude.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:ngTransclude 6 | * 7 | * @description 8 | * Вставляет содержимое элемента DOM в месте применения директивы. 9 | * 10 | * @element ANY 11 | * 12 | * @example 13 | 14 | 15 | 35 |
36 |
37 |
38 | {{text}} 39 |
40 |
41 | 42 | it('should have transcluded', function() { 43 | input('title').enter('TITLE'); 44 | input('text').enter('TEXT'); 45 | expect(binding('title')).toEqual('TITLE'); 46 | expect(binding('text')).toEqual('TEXT'); 47 | }); 48 | 49 |
50 | * 51 | */ 52 | var ngTranscludeDirective = ngDirective({ 53 | controller: ['$transclude', '$element', function($transclude, $element) { 54 | $transclude(function(clone) { 55 | $element.append(clone); 56 | }); 57 | }] 58 | }); 59 | -------------------------------------------------------------------------------- /src/ng/directive/script.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc directive 5 | * @name ng.directive:script 6 | * 7 | * @description 8 | * Загружает содержимое тега script с типом `text/ng-template`, в `$templateCache`, 9 | * так что шаблон может быть использован в `ngInclude`,` ngView` или шаблонах директив. 10 | * 11 | * @restrict E 12 | * @param {'text/ng-template'} type должен быть установлен в `'text/ng-template'` 13 | * 14 | * @example 15 | 16 | 17 | 20 | 21 | Загрузить содержимое шаблона 22 |
23 |
24 | 25 | it('should load template defined inside script tag', function() { 26 | element('#tpl-link').click(); 27 | expect(element('#tpl-content').text()).toMatch(/Содержимое шаблона/); 28 | }); 29 | 30 |
31 | */ 32 | var scriptDirective = ['$templateCache', function($templateCache) { 33 | return { 34 | restrict: 'E', 35 | terminal: true, 36 | compile: function(element, attr) { 37 | if (attr.type == 'text/ng-template') { 38 | var templateUrl = attr.id, 39 | // IE is not consistent, in scripts we have to read .text but in other nodes we have to read .textContent 40 | text = element[0].text; 41 | 42 | $templateCache.put(templateUrl, text); 43 | } 44 | } 45 | }; 46 | }]; 47 | -------------------------------------------------------------------------------- /src/ng/directive/style.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var styleDirective = valueFn({ 4 | restrict: 'E', 5 | terminal: true 6 | }); 7 | -------------------------------------------------------------------------------- /src/ng/document.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc object 5 | * @name ng.$document 6 | * @requires $window 7 | * 8 | * @description 9 | * Это {@link angular.element jQuery (lite)}-обертка, ссылающаяся на элемент браузера `window.document`. 10 | */ 11 | function $DocumentProvider(){ 12 | this.$get = ['$window', function(window){ 13 | return jqLite(window.document); 14 | }]; 15 | } 16 | -------------------------------------------------------------------------------- /src/ng/exceptionHandler.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc function 5 | * @name ng.$exceptionHandler 6 | * @requires $log 7 | * 8 | * @description 9 | * Любое не перехваченное исключение в angular-выражениях обрабатывается этим сервисом. 10 | * По умолчанию реализована обработка с помощью `$log.error`, которая просто выводит сообщение 11 | * об исключении в консоль браузера. 12 | * 13 | * В юнит тестах, если загружен `angular-mocks.js`, этот сервис будет переопределен на 14 | * {@link ngMock.$exceptionHandler mock $exceptionHandler} с вспомогательными средствами для тестирования. 15 | * 16 | * @param {Error} exception Исключение, ассоциированное с ошибкой. 17 | * @param {string=} необязательная информация о контексте в котором возникла ошибка. 18 | * 19 | */ 20 | function $ExceptionHandlerProvider() { 21 | this.$get = ['$log', function($log) { 22 | return function(exception, cause) { 23 | $log.error.apply($log, arguments); 24 | }; 25 | }]; 26 | } 27 | -------------------------------------------------------------------------------- /src/ng/rootElement.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc overview 5 | * @name ng.$rootElement 6 | * 7 | * @description 8 | * Корневой элемент приложения Angular. Это элемент в котором определена директива {@link 9 | * ng.directive:ngApp ngApp} или элемент, переданный в метод {@link angular.bootstrap}. В нем публикуется 10 | * ссылка на сервис {@link AUTO.$injector $injector} для приложения, который можно получить с помощью 11 | * `$rootElement.injector()`. 12 | */ 13 | 14 | 15 | // the implementation is in angular.bootstrap 16 | -------------------------------------------------------------------------------- /src/ng/routeParams.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc object 5 | * @name ng.$routeParams 6 | * @requires $route 7 | * 8 | * @description 9 | * Текущие параметры для маршрутизации. Параметры маршрутизации, это комбинация методов сервиса 10 | * {@link ng.$location $location} `search()`, и `path()`. Параметр `path` извлечен, когда найдет путь в 11 | * {@link ng.$route $route}. 12 | * 13 | * В случае конфликта имен параметров, параметры `path` приоритетнее параметров `search`. 14 | * 15 | * Сервис гарантирует что объект `$routeParams` не будет изменяться (но его свойства будут меняться) 16 | * даже когда маршрут будет изменен. 17 | * 18 | * @example 19 | *
20 |  *  // Дано:
21 |  *  // URL: http://server.com/index.html#/Chapter/1/Section/2?search=moby
22 |  *  // Маршрут: /Chapter/:chapterId/Section/:sectionId
23 |  *  //
24 |  *  // Тогда
25 |  *  $routeParams ==> {chapterId:1, sectionId:2, search:'moby'}
26 |  * 
27 | */ 28 | function $RouteParamsProvider() { 29 | this.$get = valueFn({}); 30 | } 31 | -------------------------------------------------------------------------------- /src/ng/window.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc object 5 | * @name ng.$window 6 | * 7 | * @description 8 | * Просто ссылка на объект браузера `window`. Хотя `window` и доступен глобально в JavaScript, 9 | * при его использовании возникает проблема при тестировании, т.к. он является глобальной переменной. 10 | * В Angular мы всегда ссылаемся на него через сервис `$window`, т.к. в этом случае его можно переопределить, 11 | * удалить или заменить другим при тестировании. 12 | * 13 | * Любые выражения, вычисляемые в любой области видимости не должны работать с глобальным объектом `window`. 14 | * 15 | * @example 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | */ 25 | function $WindowProvider(){ 26 | this.$get = valueFn(window); 27 | } 28 | -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_chr.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"DATETIME_FORMATS":{"MONTH":["ᎤᏃᎸᏔᏅ","ᎧᎦᎵ","ᎠᏅᏱ","ᎧᏬᏂ","ᎠᏂᏍᎬᏘ","ᏕᎭᎷᏱ","ᎫᏰᏉᏂ","ᎦᎶᏂ","ᏚᎵᏍᏗ","ᏚᏂᏅᏗ","ᏅᏓᏕᏆ","ᎤᏍᎩᏱ"],"SHORTMONTH":["ᎤᏃ","ᎧᎦ","ᎠᏅ","ᎧᏬ","ᎠᏂ","ᏕᎭ","ᎫᏰ","ᎦᎶ","ᏚᎵ","ᏚᏂ","ᏅᏓ","ᎤᏍ"],"DAY":["ᎤᎾᏙᏓᏆᏍᎬ","ᎤᎾᏙᏓᏉᏅᎯ","ᏔᎵᏁᎢᎦ","ᏦᎢᏁᎢᎦ","ᏅᎩᏁᎢᎦ","ᏧᎾᎩᎶᏍᏗ","ᎤᎾᏙᏓᏈᏕᎾ"],"SHORTDAY":["ᏆᏍᎬ","ᏉᏅᎯ","ᏔᎵᏁ","ᏦᎢᏁ","ᏅᎩᏁ","ᏧᎾᎩ","ᏈᏕᎾ"],"AMPMS":["ᏌᎾᎴ","ᏒᎯᏱᎢᏗᏢ"],"medium":"MMM d, y h:mm:ss a","short":"M/d/yy h:mm a","fullDate":"EEEE, MMMM d, y","longDate":"MMMM d, y","mediumDate":"MMM d, y","shortDate":"M/d/yy","mediumTime":"h:mm:ss a","shortTime":"h:mm a"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"id":"chr"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_cy.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"DATETIME_FORMATS":{"MONTH":["Ionawr","Chwefror","Mawrth","Ebrill","Mai","Mehefin","Gorffenaf","Awst","Medi","Hydref","Tachwedd","Rhagfyr"],"SHORTMONTH":["Ion","Chwef","Mawrth","Ebrill","Mai","Meh","Gorff","Awst","Medi","Hyd","Tach","Rhag"],"DAY":["Dydd Sul","Dydd Llun","Dydd Mawrth","Dydd Mercher","Dydd Iau","Dydd Gwener","Dydd Sadwrn"],"SHORTDAY":["Sul","Llun","Maw","Mer","Iau","Gwen","Sad"],"AMPMS":["AM","PM"],"medium":"d MMM y HH:mm:ss","short":"dd/MM/yyyy HH:mm","fullDate":"EEEE, d MMMM y","longDate":"d MMMM y","mediumDate":"d MMM y","shortDate":"dd/MM/yyyy","mediumTime":"HH:mm:ss","shortTime":"HH:mm"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"id":"cy"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_el-polyton.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"NUMBER_FORMATS":{"DECIMAL_SEP":",","GROUP_SEP":".","PATTERNS":[{"minInt":1,"minFrac":0,"macFrac":0,"posPre":"","posSuf":"","negPre":"-","negSuf":"","gSize":3,"lgSize":3,"maxFrac":3},{"minInt":1,"minFrac":2,"macFrac":0,"posPre":"","posSuf":" \u00A4","negPre":"-","negSuf":" \u00A4","gSize":3,"lgSize":3,"maxFrac":2}],"CURRENCY_SYM":"€"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"DATETIME_FORMATS":{"MONTH":["Ιανουαρίου","Φεβρουαρίου","Μαρτίου","Απριλίου","Μαΐου","Ιουνίου","Ιουλίου","Αυγούστου","Σεπτεμβρίου","Οκτωβρίου","Νοεμβρίου","Δεκεμβρίου"],"SHORTMONTH":["Ιαν","Φεβ","Μαρ","Απρ","Μαϊ","Ιουν","Ιουλ","Αυγ","Σεπ","Οκτ","Νοε","Δεκ"],"DAY":["Κυριακή","Δευτέρα","Τρίτη","Τετάρτη","Πέμπτη","Παρασκευή","Σάββατο"],"SHORTDAY":["Κυρ","Δευ","Τρι","Τετ","Πεμ","Παρ","Σαβ"],"AMPMS":["π.μ.","μ.μ."],"medium":"d MMM y h:mm:ss a","short":"d/M/yy h:mm a","fullDate":"EEEE, d MMMM y","longDate":"d MMMM y","mediumDate":"d MMM y","shortDate":"d/M/yy","mediumTime":"h:mm:ss a","shortTime":"h:mm a"},"id":"el-polyton"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_en-zz.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"NUMBER_FORMATS":{"DECIMAL_SEP":".","GROUP_SEP":",","PATTERNS":[{"minInt":1,"minFrac":0,"macFrac":0,"posPre":"","posSuf":"","negPre":"-","negSuf":"","gSize":3,"lgSize":3,"maxFrac":3},{"minInt":1,"minFrac":2,"macFrac":0,"posPre":"\u00A4","posSuf":"","negPre":"(\u00A4","negSuf":")","gSize":3,"lgSize":3,"maxFrac":2}],"CURRENCY_SYM":"$"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"DATETIME_FORMATS":{"MONTH":["January","February","March","April","May","June","July","August","September","October","November","December"],"SHORTMONTH":["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],"DAY":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],"SHORTDAY":["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],"AMPMS":["AM","PM"],"medium":"MMM d, y h:mm:ss a","short":"M/d/yy h:mm a","fullDate":"EEEE, MMMM d, y","longDate":"MMMM d, y","mediumDate":"MMM d, y","shortDate":"M/d/yy","mediumTime":"h:mm:ss a","shortTime":"h:mm a"},"id":"en-zz"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_haw.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"DATETIME_FORMATS":{"MONTH":["Ianuali","Pepeluali","Malaki","ʻApelila","Mei","Iune","Iulai","ʻAukake","Kepakemapa","ʻOkakopa","Nowemapa","Kekemapa"],"SHORTMONTH":["Ian.","Pep.","Mal.","ʻAp.","Mei","Iun.","Iul.","ʻAu.","Kep.","ʻOk.","Now.","Kek."],"DAY":["Lāpule","Poʻakahi","Poʻalua","Poʻakolu","Poʻahā","Poʻalima","Poʻaono"],"SHORTDAY":["LP","P1","P2","P3","P4","P5","P6"],"AMPMS":["AM","PM"],"medium":"d MMM y h:mm:ss a","short":"d/M/yy h:mm a","fullDate":"EEEE, d MMMM y","longDate":"d MMMM y","mediumDate":"d MMM y","shortDate":"d/M/yy","mediumTime":"h:mm:ss a","shortTime":"h:mm a"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"id":"haw"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_mo.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"DATETIME_FORMATS":{"MONTH":["ianuarie","februarie","martie","aprilie","mai","iunie","iulie","august","septembrie","octombrie","noiembrie","decembrie"],"SHORTMONTH":["ian.","feb.","mar.","apr.","mai","iun.","iul.","aug.","sept.","oct.","nov.","dec."],"DAY":["duminică","luni","marți","miercuri","joi","vineri","sâmbătă"],"SHORTDAY":["Du","Lu","Ma","Mi","Jo","Vi","Sâ"],"AMPMS":["AM","PM"],"medium":"dd.MM.yyyy HH:mm:ss","short":"dd.MM.yyyy HH:mm","fullDate":"EEEE, d MMMM y","longDate":"d MMMM y","mediumDate":"dd.MM.yyyy","shortDate":"dd.MM.yyyy","mediumTime":"HH:mm:ss","shortTime":"HH:mm"},"NUMBER_FORMATS":{"DECIMAL_SEP":",","GROUP_SEP":".","PATTERNS":[{"minInt":1,"minFrac":0,"macFrac":0,"posPre":"","posSuf":"","negPre":"-","negSuf":"","gSize":3,"lgSize":3,"maxFrac":3},{"minInt":1,"minFrac":2,"macFrac":0,"posPre":"","posSuf":" \u00A4","negPre":"-","negSuf":" \u00A4","gSize":3,"lgSize":3,"maxFrac":2}],"CURRENCY_SYM":"MDL"},"pluralCat":function (n) { if (n == 1) { return PLURAL_CATEGORY.ONE; } if (n == 0 || n != 1 && (n % 100) >= 1 && (n % 100) <= 19 && n == Math.floor(n)) { return PLURAL_CATEGORY.FEW; } return PLURAL_CATEGORY.OTHER;},"id":"mo"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_sr-rs.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"NUMBER_FORMATS":{"DECIMAL_SEP":".","GROUP_SEP":",","PATTERNS":[{"minInt":1,"minFrac":0,"macFrac":0,"posPre":"","posSuf":"","negPre":"-","negSuf":"","gSize":3,"lgSize":3,"maxFrac":3},{"minInt":1,"minFrac":2,"macFrac":0,"posPre":"","posSuf":" \u00A4","negPre":"-","negSuf":" \u00A4","gSize":3,"lgSize":3,"maxFrac":2}],"CURRENCY_SYM":"РСД"},"pluralCat":function (n) { if ((n % 10) == 1 && (n % 100) != 11) { return PLURAL_CATEGORY.ONE; } if ((n % 10) >= 2 && (n % 10) <= 4 && ((n % 100) < 12 || (n % 100) > 14) && n == Math.floor(n)) { return PLURAL_CATEGORY.FEW; } if ((n % 10) == 0 || ((n % 10) >= 5 && (n % 10) <= 9) || ((n % 100) >= 11 && (n % 100) <= 14) && n == Math.floor(n)) { return PLURAL_CATEGORY.MANY; } return PLURAL_CATEGORY.OTHER;},"DATETIME_FORMATS":{"MONTH":["јануар","фебруар","март","април","мај","јун","јул","август","септембар","октобар","новембар","децембар"],"SHORTMONTH":["јан","феб","мар","апр","мај","јун","јул","авг","сеп","окт","нов","дец"],"DAY":["недеља","понедељак","уторак","среда","четвртак","петак","субота"],"SHORTDAY":["нед","пон","уто","сре","чет","пет","суб"],"AMPMS":["пре подне","поподне"],"medium":"dd.MM.y. HH.mm.ss","short":"d.M.yy. HH.mm","fullDate":"EEEE, dd. MMMM y.","longDate":"dd. MMMM y.","mediumDate":"dd.MM.y.","shortDate":"d.M.yy.","mediumTime":"HH.mm.ss","shortTime":"HH.mm"},"id":"sr-rs"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngLocale/angular-locale_tl-ph.js: -------------------------------------------------------------------------------- 1 | angular.module("ngLocale", [], ["$provide", function($provide) { 2 | var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; 3 | $provide.value("$locale", {"NUMBER_FORMATS":{"DECIMAL_SEP":".","GROUP_SEP":",","PATTERNS":[{"minInt":1,"minFrac":0,"macFrac":0,"posPre":"","posSuf":"","negPre":"-","negSuf":"","gSize":3,"lgSize":3,"maxFrac":3},{"minInt":1,"minFrac":2,"macFrac":0,"posPre":"\u00A4 ","posSuf":"","negPre":"\u00A4 -","negSuf":"","gSize":3,"lgSize":3,"maxFrac":2}],"CURRENCY_SYM":"P"},"pluralCat":function (n) { if (n == 0 || n == 1) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;},"DATETIME_FORMATS":{"MONTH":["Enero","Pebrero","Marso","Abril","Mayo","Hunyo","Hulyo","Agosto","Setyembre","Oktubre","Nobyembre","Disyembre"],"SHORTMONTH":["Ene","Peb","Mar","Abr","May","Hun","Hul","Ago","Set","Okt","Nob","Dis"],"DAY":["Linggo","Lunes","Martes","Miyerkules","Huwebes","Biyernes","Sabado"],"SHORTDAY":["Lin","Lun","Mar","Mye","Huw","Bye","Sab"],"AMPMS":["AM","PM"],"medium":"MMM d, y HH:mm:ss","short":"M/d/yy HH:mm","fullDate":"EEEE, MMMM dd y","longDate":"MMMM d, y","mediumDate":"MMM d, y","shortDate":"M/d/yy","mediumTime":"HH:mm:ss","shortTime":"HH:mm"},"id":"tl-ph"}); 4 | }]); -------------------------------------------------------------------------------- /src/ngMobile/mobile.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * @ngdoc overview 5 | * @name ngMobile 6 | * @description 7 | * Touch events and other mobile helpers. 8 | * Based on jQuery Mobile touch event handling (jquerymobile.com) 9 | */ 10 | 11 | // define ngMobile module 12 | var ngMobile = angular.module('ngMobile', []); 13 | 14 | -------------------------------------------------------------------------------- /src/ngSanitize/directive/ngBindHtml.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | 4 | /** 5 | * @ngdoc directive 6 | * @name ngSanitize.directive:ngBindHtml 7 | * 8 | * @description 9 | * Создает привязки, которые очищают результат вычисления выражения `expression` с помощью сервиса 10 | * {@link ngSanitize.$sanitize $sanitize} и результат устанавливается с помощью innerHTML в текущий элемент. 11 | * 12 | * См. пример в документации по {@link ngSanitize.$sanitize $sanitize}. 13 | * 14 | * @element ANY 15 | * @param {expression} ngBindHtml {@link guide/expression Выражение} для вычисления. 16 | */ 17 | angular.module('ngSanitize').directive('ngBindHtml', ['$sanitize', function($sanitize) { 18 | return function(scope, element, attr) { 19 | element.addClass('ng-binding').data('$binding', attr.ngBindHtml); 20 | scope.$watch(attr.ngBindHtml, function ngBindHtmlWatchAction(value) { 21 | value = $sanitize(value); 22 | element.html(value || ''); 23 | }); 24 | }; 25 | }]); 26 | -------------------------------------------------------------------------------- /src/ngScenario/Future.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * A future action in a spec. 5 | * 6 | * @param {string} name of the future action 7 | * @param {function()} future callback(error, result) 8 | * @param {function()} Optional. function that returns the file/line number. 9 | */ 10 | angular.scenario.Future = function(name, behavior, line) { 11 | this.name = name; 12 | this.behavior = behavior; 13 | this.fulfilled = false; 14 | this.value = undefined; 15 | this.parser = angular.identity; 16 | this.line = line || function() { return ''; }; 17 | }; 18 | 19 | /** 20 | * Executes the behavior of the closure. 21 | * 22 | * @param {function()} doneFn Callback function(error, result) 23 | */ 24 | angular.scenario.Future.prototype.execute = function(doneFn) { 25 | var self = this; 26 | this.behavior(function(error, result) { 27 | self.fulfilled = true; 28 | if (result) { 29 | try { 30 | result = self.parser(result); 31 | } catch(e) { 32 | error = e; 33 | } 34 | } 35 | self.value = error || result; 36 | doneFn(error, result); 37 | }); 38 | }; 39 | 40 | /** 41 | * Configures the future to convert it's final with a function fn(value) 42 | * 43 | * @param {function()} fn function(value) that returns the parsed value 44 | */ 45 | angular.scenario.Future.prototype.parsedWith = function(fn) { 46 | this.parser = fn; 47 | return this; 48 | }; 49 | 50 | /** 51 | * Configures the future to parse it's final value from JSON 52 | * into objects. 53 | */ 54 | angular.scenario.Future.prototype.fromJson = function() { 55 | return this.parsedWith(angular.fromJson); 56 | }; 57 | 58 | /** 59 | * Configures the future to convert it's final value from objects 60 | * into JSON. 61 | */ 62 | angular.scenario.Future.prototype.toJson = function() { 63 | return this.parsedWith(angular.toJson); 64 | }; 65 | -------------------------------------------------------------------------------- /src/ngScenario/angular-bootstrap.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | (function(previousOnLoad){ 4 | var prefix = (function() { 5 | var filename = /(.*\/)angular-bootstrap.js(#(.*))?/; 6 | var scripts = document.getElementsByTagName("script"); 7 | for(var j = 0; j < scripts.length; j++) { 8 | var src = scripts[j].src; 9 | if (src && src.match(filename)) { 10 | var parts = src.match(filename); 11 | return parts[1]; 12 | } 13 | } 14 | })(); 15 | 16 | function addScript(path) { 17 | document.write(''); 18 | } 19 | 20 | function addCSS(path) { 21 | document.write(''); 22 | } 23 | 24 | window.onload = function() { 25 | try { 26 | if (previousOnLoad) previousOnLoad(); 27 | } catch(e) {} 28 | angular.scenario.setUpAndRun({}); 29 | }; 30 | 31 | addCSS("../../css/angular-scenario.css"); 32 | addScript("../../lib/jquery/jquery.js"); 33 | document.write( 34 | '' 37 | ); 38 | addScript("../angular-bootstrap.js"); 39 | 40 | addScript("Scenario.js"); 41 | addScript("Application.js"); 42 | addScript("Describe.js"); 43 | addScript("Future.js"); 44 | addScript("Runner.js"); 45 | addScript("SpecRunner.js"); 46 | addScript("dsl.js"); 47 | addScript("matchers.js"); 48 | addScript("ObjectModel.js"); 49 | addScript("output/Html.js"); 50 | addScript("output/Json.js"); 51 | addScript("output/Object.js"); 52 | addScript("output/Xml.js"); 53 | 54 | // Create the runner (which also sets up the global API) 55 | document.write( 56 | ''); 59 | 60 | })(window.onload); 61 | -------------------------------------------------------------------------------- /src/ngScenario/angular.prefix: -------------------------------------------------------------------------------- 1 | /** 2 | * @license AngularJS v"NG_VERSION_FULL" 3 | * (c) 2010-2012 Google, Inc. http://angularjs.org 4 | * License: MIT 5 | */ 6 | (function(window, document){ 7 | var _jQuery = window.jQuery.noConflict(true); 8 | -------------------------------------------------------------------------------- /src/ngScenario/angular.suffix: -------------------------------------------------------------------------------- 1 | bindJQuery(); 2 | publishExternalAPI(angular); 3 | 4 | var $runner = new angular.scenario.Runner(window), 5 | scripts = document.getElementsByTagName('script'), 6 | script = scripts[scripts.length - 1], 7 | config = {}; 8 | 9 | angular.forEach(script.attributes, function(attr) { 10 | var match = attr.name.match(/ng[:\-](.*)/); 11 | if (match) { 12 | config[match[1]] = attr.value || true; 13 | } 14 | }); 15 | 16 | if (config.autotest) { 17 | JQLite(document).ready(function() { 18 | angular.scenario.setUpAndRun(config); 19 | }); 20 | } 21 | })(window, document); 22 | 23 | -------------------------------------------------------------------------------- /src/ngScenario/matchers.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Matchers for implementing specs. Follows the Jasmine spec conventions. 5 | */ 6 | 7 | angular.scenario.matcher('toEqual', function(expected) { 8 | return angular.equals(this.actual, expected); 9 | }); 10 | 11 | angular.scenario.matcher('toBe', function(expected) { 12 | return this.actual === expected; 13 | }); 14 | 15 | angular.scenario.matcher('toBeDefined', function() { 16 | return angular.isDefined(this.actual); 17 | }); 18 | 19 | angular.scenario.matcher('toBeTruthy', function() { 20 | return this.actual; 21 | }); 22 | 23 | angular.scenario.matcher('toBeFalsy', function() { 24 | return !this.actual; 25 | }); 26 | 27 | angular.scenario.matcher('toMatch', function(expected) { 28 | return new RegExp(expected).test(this.actual); 29 | }); 30 | 31 | angular.scenario.matcher('toBeNull', function() { 32 | return this.actual === null; 33 | }); 34 | 35 | angular.scenario.matcher('toContain', function(expected) { 36 | return includes(this.actual, expected); 37 | }); 38 | 39 | angular.scenario.matcher('toBeLessThan', function(expected) { 40 | return this.actual < expected; 41 | }); 42 | 43 | angular.scenario.matcher('toBeGreaterThan', function(expected) { 44 | return this.actual > expected; 45 | }); 46 | -------------------------------------------------------------------------------- /src/ngScenario/output/Json.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Generates JSON output into a context. 5 | */ 6 | angular.scenario.output('json', function(context, runner, model) { 7 | model.on('RunnerEnd', function() { 8 | context.text(angular.toJson(model.value)); 9 | }); 10 | }); 11 | -------------------------------------------------------------------------------- /src/ngScenario/output/Object.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Creates a global value $result with the result of the runner. 5 | */ 6 | angular.scenario.output('object', function(context, runner, model) { 7 | runner.$window.$result = model.value; 8 | }); 9 | -------------------------------------------------------------------------------- /src/ngScenario/output/Xml.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Generates XML output into a context. 5 | */ 6 | angular.scenario.output('xml', function(context, runner, model) { 7 | var $ = function(args) {return new context.init(args);}; 8 | model.on('RunnerEnd', function() { 9 | var scenario = $(''); 10 | context.append(scenario); 11 | serializeXml(scenario, model.value); 12 | }); 13 | 14 | /** 15 | * Convert the tree into XML. 16 | * 17 | * @param {Object} context jQuery context to add the XML to. 18 | * @param {Object} tree node to serialize 19 | */ 20 | function serializeXml(context, tree) { 21 | angular.forEach(tree.children, function(child) { 22 | var describeContext = $(''); 23 | describeContext.attr('id', child.id); 24 | describeContext.attr('name', child.name); 25 | context.append(describeContext); 26 | serializeXml(describeContext, child); 27 | }); 28 | var its = $(''); 29 | context.append(its); 30 | angular.forEach(tree.specs, function(spec) { 31 | var it = $(''); 32 | it.attr('id', spec.id); 33 | it.attr('name', spec.name); 34 | it.attr('duration', spec.duration); 35 | it.attr('status', spec.status); 36 | its.append(it); 37 | angular.forEach(spec.steps, function(step) { 38 | var stepContext = $(''); 39 | stepContext.attr('name', step.name); 40 | stepContext.attr('duration', step.duration); 41 | stepContext.attr('status', step.status); 42 | it.append(stepContext); 43 | if (step.error) { 44 | var error = $(''); 45 | stepContext.append(error); 46 | error.text(formatException(step.error)); 47 | } 48 | }); 49 | }); 50 | } 51 | }); 52 | -------------------------------------------------------------------------------- /src/publishExternalApis.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | publishExternalAPI(angular); 4 | -------------------------------------------------------------------------------- /start-iteration.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | ./version.js --minor-bump 4 | VERSION=`./version.js --curent` 5 | git commit -a -m "chore(relase): start v$VERSION iteration" 6 | -------------------------------------------------------------------------------- /test/ApiSpecs.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('api', function() { 4 | 5 | describe('HashMap', function() { 6 | it('should do basic crud', function() { 7 | var map = new HashMap(); 8 | var key = {}; 9 | var value1 = {}; 10 | var value2 = {}; 11 | map.put(key, value1); 12 | map.put(key, value2); 13 | expect(map.get(key)).toBe(value2); 14 | expect(map.get({})).toBe(undefined); 15 | expect(map.remove(key)).toBe(value2); 16 | expect(map.get(key)).toBe(undefined); 17 | }); 18 | 19 | it('should init from an array', function() { 20 | var map = new HashMap(['a','b']); 21 | expect(map.get('a')).toBe(0); 22 | expect(map.get('b')).toBe(1); 23 | expect(map.get('c')).toBe(undefined); 24 | }); 25 | }); 26 | }); 27 | 28 | -------------------------------------------------------------------------------- /test/e2e/runner.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | End2end Test Runner 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /test/e2e/scenarios.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* http://docs.angularjs.org/guide/dev_guide.e2e-testing */ 4 | 5 | describe('my app', function() { 6 | 7 | beforeEach(function() { 8 | browser().navigateTo('../../app/index.html'); 9 | }); 10 | 11 | 12 | it('should automatically redirect to /view1 when location hash/fragment is empty', function() { 13 | expect(browser().location().url()).toBe("/view1"); 14 | }); 15 | 16 | 17 | describe('view1', function() { 18 | 19 | beforeEach(function() { 20 | browser().navigateTo('#/view1'); 21 | }); 22 | 23 | 24 | it('should render view1 when user navigates to /view1', function() { 25 | expect(element('[ng-view] p:first').text()). 26 | toMatch(/partial for view 1/); 27 | }); 28 | 29 | }); 30 | 31 | 32 | describe('view2', function() { 33 | 34 | beforeEach(function() { 35 | browser().navigateTo('#/view2'); 36 | }); 37 | 38 | 39 | it('should render view2 when user navigates to /view2', function() { 40 | expect(element('[ng-view] p:first').text()). 41 | toMatch(/partial for view 2/); 42 | }); 43 | 44 | }); 45 | }); 46 | -------------------------------------------------------------------------------- /test/jQueryPatchSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | if (window.jQuery) { 4 | 5 | describe('jQuery patch', function() { 6 | 7 | var doc = null; 8 | var divSpy = null; 9 | var spy1 = null; 10 | var spy2 = null; 11 | 12 | beforeEach(function() { 13 | divSpy = jasmine.createSpy('div.$destroy'); 14 | spy1 = jasmine.createSpy('span1.$destroy'); 15 | spy2 = jasmine.createSpy('span2.$destroy'); 16 | doc = $('
abcxyz
'); 17 | doc.find('span.first').bind('$destroy', spy1); 18 | doc.find('span.second').bind('$destroy', spy2); 19 | }); 20 | 21 | afterEach(function() { 22 | expect(divSpy).not.toHaveBeenCalled(); 23 | 24 | expect(spy1).toHaveBeenCalled(); 25 | expect(spy1.callCount).toEqual(1); 26 | expect(spy2).toHaveBeenCalled(); 27 | expect(spy2.callCount).toEqual(1); 28 | }); 29 | 30 | describe('$detach event', function() { 31 | 32 | it('should fire on detach()', function() { 33 | doc.find('span').detach(); 34 | }); 35 | 36 | it('should fire on remove()', function() { 37 | doc.find('span').remove(); 38 | }); 39 | 40 | it('should fire on replaceWith()', function() { 41 | doc.find('span').replaceWith('bla'); 42 | }); 43 | 44 | it('should fire on replaceAll()', function() { 45 | $('bla').replaceAll(doc.find('span')); 46 | }); 47 | 48 | it('should fire on empty()', function() { 49 | doc.empty(); 50 | }); 51 | 52 | it('should fire on html()', function() { 53 | doc.html('abc'); 54 | }); 55 | }); 56 | }); 57 | } 58 | -------------------------------------------------------------------------------- /test/jquery_alias.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var _jQuery = jQuery, 4 | _jqLiteMode = false; 5 | -------------------------------------------------------------------------------- /test/jquery_remove.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var _jQuery = jQuery.noConflict(true), 4 | _jqLiteMode = true; 5 | -------------------------------------------------------------------------------- /test/lib/angular/version.txt: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /test/ng/animationSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$animation', function() { 4 | 5 | it('should allow animation registration', function() { 6 | var noopCustom = function(){}; 7 | module(function($animationProvider) { 8 | $animationProvider.register('noop-custom', valueFn(noopCustom)); 9 | }); 10 | inject(function($animation) { 11 | expect($animation('noop-custom')).toBe(noopCustom); 12 | }); 13 | }); 14 | 15 | }); 16 | -------------------------------------------------------------------------------- /test/ng/directive/aSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('a', function() { 4 | var element, $compile, $rootScope; 5 | 6 | 7 | beforeEach(inject(function(_$compile_, _$rootScope_) { 8 | $compile = _$compile_; 9 | $rootScope = _$rootScope_; 10 | })); 11 | 12 | 13 | afterEach(function(){ 14 | dealoc(element); 15 | }); 16 | 17 | 18 | it('should prevent default action to be executed when href is empty', function() { 19 | var orgLocation = document.location.href, 20 | preventDefaultCalled = false, 21 | event; 22 | 23 | element = $compile('empty link')($rootScope); 24 | 25 | if (msie < 9) { 26 | 27 | event = document.createEventObject(); 28 | expect(event.returnValue).not.toBeDefined(); 29 | element[0].fireEvent('onclick', event); 30 | expect(event.returnValue).toEqual(false); 31 | 32 | } else { 33 | 34 | event = document.createEvent('MouseEvent'); 35 | event.initMouseEvent( 36 | 'click', true, true, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null); 37 | 38 | event.preventDefaultOrg = event.preventDefault; 39 | event.preventDefault = function() { 40 | preventDefaultCalled = true; 41 | if (this.preventDefaultOrg) this.preventDefaultOrg(); 42 | }; 43 | 44 | element[0].dispatchEvent(event); 45 | 46 | expect(preventDefaultCalled).toEqual(true); 47 | } 48 | 49 | expect(document.location.href).toEqual(orgLocation); 50 | }); 51 | 52 | 53 | it('should prevent IE for changing text content when setting attribute', function() { 54 | // see issue #1949 55 | element = jqLite('hello@you'); 56 | $compile(element); 57 | element.attr('href', 'bye@me'); 58 | 59 | expect(element.text()).toBe('hello@you'); 60 | }); 61 | }); 62 | -------------------------------------------------------------------------------- /test/ng/directive/ngClickSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngClick', function() { 4 | var element; 5 | 6 | afterEach(function() { 7 | dealoc(element); 8 | }); 9 | 10 | it('should get called on a click', inject(function($rootScope, $compile) { 11 | element = $compile('
')($rootScope); 12 | $rootScope.$digest(); 13 | expect($rootScope.clicked).toBeFalsy(); 14 | 15 | browserTrigger(element, 'click'); 16 | expect($rootScope.clicked).toEqual(true); 17 | })); 18 | 19 | it('should pass event object', inject(function($rootScope, $compile) { 20 | element = $compile('
')($rootScope); 21 | $rootScope.$digest(); 22 | 23 | browserTrigger(element, 'click'); 24 | expect($rootScope.event).toBeDefined(); 25 | })); 26 | }); 27 | -------------------------------------------------------------------------------- /test/ng/directive/ngCloakSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngCloak', function() { 4 | var element; 5 | 6 | 7 | afterEach(function() { 8 | dealoc(element); 9 | }); 10 | 11 | 12 | it('should get removed when an element is compiled', inject(function($rootScope, $compile) { 13 | element = jqLite('
'); 14 | expect(element.attr('ng-cloak')).toBe(''); 15 | $compile(element); 16 | expect(element.attr('ng-cloak')).toBeUndefined(); 17 | })); 18 | 19 | 20 | it('should remove ngCloak class from a compiled element with attribute', inject( 21 | function($rootScope, $compile) { 22 | element = jqLite('
'); 23 | 24 | expect(element.hasClass('foo')).toBe(true); 25 | expect(element.hasClass('ng-cloak')).toBe(true); 26 | expect(element.hasClass('bar')).toBe(true); 27 | 28 | $compile(element); 29 | 30 | expect(element.hasClass('foo')).toBe(true); 31 | expect(element.hasClass('ng-cloak')).toBe(false); 32 | expect(element.hasClass('bar')).toBe(true); 33 | })); 34 | 35 | 36 | it('should remove ngCloak class from a compiled element', inject(function($rootScope, $compile) { 37 | element = jqLite('
'); 38 | 39 | expect(element.hasClass('foo')).toBe(true); 40 | expect(element.hasClass('ng-cloak')).toBe(true); 41 | expect(element.hasClass('bar')).toBe(true); 42 | 43 | $compile(element); 44 | 45 | expect(element.hasClass('foo')).toBe(true); 46 | expect(element.hasClass('ng-cloak')).toBe(false); 47 | expect(element.hasClass('bar')).toBe(true); 48 | })); 49 | }); 50 | -------------------------------------------------------------------------------- /test/ng/directive/ngCspSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngCsp', function() { 4 | 5 | it('it should turn on CSP mode in $sniffer', inject(function($sniffer, $compile) { 6 | expect($sniffer.csp).toBe(false); 7 | $compile('
'); 8 | expect($sniffer.csp).toBe(true); 9 | })); 10 | }); 11 | -------------------------------------------------------------------------------- /test/ng/directive/ngEventDirsSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('event directives', function() { 4 | var element; 5 | 6 | 7 | afterEach(function() { 8 | dealoc(element); 9 | }); 10 | 11 | 12 | describe('ngSubmit', function() { 13 | 14 | it('should get called on form submit', inject(function($rootScope, $compile) { 15 | element = $compile('
' + 16 | '' + 17 | '
')($rootScope); 18 | $rootScope.$digest(); 19 | expect($rootScope.submitted).not.toBeDefined(); 20 | 21 | browserTrigger(element.children()[0]); 22 | expect($rootScope.submitted).toEqual(true); 23 | })); 24 | }); 25 | }); 26 | -------------------------------------------------------------------------------- /test/ng/directive/ngInitSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngInit', function() { 4 | var element; 5 | 6 | 7 | afterEach(function() { 8 | dealoc(element); 9 | }); 10 | 11 | 12 | it("should init model", inject(function($rootScope, $compile) { 13 | element = $compile('
')($rootScope); 14 | expect($rootScope.a).toEqual(123); 15 | })); 16 | }); 17 | -------------------------------------------------------------------------------- /test/ng/directive/ngKeySpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngKeyup and ngKeydown directives', function() { 4 | var element; 5 | 6 | afterEach(function() { 7 | dealoc(element); 8 | }); 9 | 10 | it('should get called on a keyup', inject(function($rootScope, $compile) { 11 | element = $compile('')($rootScope); 12 | $rootScope.$digest(); 13 | expect($rootScope.touched).toBeFalsy(); 14 | 15 | browserTrigger(element, 'keyup'); 16 | expect($rootScope.touched).toEqual(true); 17 | })); 18 | 19 | it('should get called on a keydown', inject(function($rootScope, $compile) { 20 | element = $compile('')($rootScope); 21 | $rootScope.$digest(); 22 | expect($rootScope.touched).toBeFalsy(); 23 | 24 | browserTrigger(element, 'keydown'); 25 | expect($rootScope.touched).toEqual(true); 26 | })); 27 | 28 | it('should get called on a keypress', inject(function($rootScope, $compile) { 29 | element = $compile('')($rootScope); 30 | $rootScope.$digest(); 31 | expect($rootScope.touched).toBeFalsy(); 32 | 33 | browserTrigger(element, 'keypress'); 34 | expect($rootScope.touched).toEqual(true); 35 | })); 36 | 37 | }); 38 | 39 | -------------------------------------------------------------------------------- /test/ng/directive/ngNonBindableSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | 4 | describe('ngNonBindable', function() { 5 | var element; 6 | 7 | 8 | afterEach(function(){ 9 | dealoc(element); 10 | }); 11 | 12 | 13 | it('should prevent compilation of the owning element and its children', 14 | inject(function($rootScope, $compile) { 15 | element = $compile('
')($rootScope); 16 | $rootScope.name = 'misko'; 17 | $rootScope.$digest(); 18 | expect(element.text()).toEqual(''); 19 | expect(element.attr('text')).toEqual('{{name}}'); 20 | })); 21 | }); 22 | -------------------------------------------------------------------------------- /test/ng/directive/ngSrcSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('ngSrc', function() { 4 | var element; 5 | 6 | afterEach(function() { 7 | dealoc(element); 8 | }); 9 | 10 | it('should not result empty string in img src', inject(function($rootScope, $compile) { 11 | $rootScope.image = {}; 12 | element = $compile('')($rootScope); 13 | $rootScope.$digest(); 14 | expect(element.attr('src')).not.toBe(''); 15 | expect(element.attr('src')).toBe(undefined); 16 | })); 17 | }); 18 | -------------------------------------------------------------------------------- /test/ng/directive/scriptSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('scriptDirective', function() { 4 | var element; 5 | 6 | 7 | afterEach(function(){ 8 | dealoc(element); 9 | }); 10 | 11 | 12 | it('should populate $templateCache with contents of a ng-template script element', inject( 13 | function($compile, $templateCache) { 14 | $compile('
foo' + 15 | '' + 16 | '' + 17 | '
' ); 18 | expect($templateCache.get('/myTemplate.html')).toBe('{{y}}'); 19 | expect($templateCache.get('/ignore')).toBeUndefined(); 20 | } 21 | )); 22 | 23 | 24 | it('should not compile scripts', inject(function($compile, $templateCache, $rootScope) { 25 | var doc = jqLite('
'); 26 | // jQuery is too smart and removes script tags 27 | doc[0].innerHTML = 'foo' + 28 | '' + 29 | ''; 30 | 31 | $compile(doc)($rootScope); 32 | $rootScope.$digest(); 33 | 34 | var scripts = doc.find('script'); 35 | expect(scripts.eq(0)[0].text).toBe('some {{binding}}'); 36 | expect(scripts.eq(1)[0].text).toBe('other {{binding}}'); 37 | dealoc(doc); 38 | })); 39 | }); 40 | -------------------------------------------------------------------------------- /test/ng/directive/styleSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('style', function() { 4 | var element; 5 | 6 | 7 | afterEach(function() { 8 | dealoc(element); 9 | }); 10 | 11 | 12 | it('should not compile style element', inject(function($compile, $rootScope) { 13 | element = jqLite(''); 14 | $compile(element)($rootScope); 15 | $rootScope.$digest(); 16 | 17 | // read innerHTML and trim to pass on IE8 18 | expect(trim(element[0].innerHTML)).toBe('should {{notBound}}'); 19 | })); 20 | 21 | 22 | it('should compile content of element with style attr', inject(function($compile, $rootScope) { 23 | element = jqLite('
{{bind}}
'); 24 | $compile(element)($rootScope); 25 | $rootScope.$apply(function() { 26 | $rootScope.bind = 'value'; 27 | }); 28 | 29 | expect(element.text()).toBe('value'); 30 | })); 31 | }); 32 | -------------------------------------------------------------------------------- /test/ng/documentSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$document', function() { 4 | 5 | 6 | it("should inject $document", inject(function($document) { 7 | expect($document).toEqual(jqLite(document)); 8 | })); 9 | }); 10 | -------------------------------------------------------------------------------- /test/ng/exceptionHandlerSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$exceptionHandler', function() { 4 | it('should log errors with single argument', function() { 5 | module(function($provide){ 6 | $provide.provider('$exceptionHandler', $ExceptionHandlerProvider); 7 | }); 8 | inject(function($log, $exceptionHandler) { 9 | $exceptionHandler('myError'); 10 | expect($log.error.logs.shift()).toEqual(['myError']); 11 | }); 12 | }); 13 | 14 | 15 | it('should log errors with multiple arguments', function() { 16 | module(function($provide){ 17 | $provide.provider('$exceptionHandler', $ExceptionHandlerProvider); 18 | }); 19 | inject(function($log, $exceptionHandler) { 20 | $exceptionHandler('myError', 'comment'); 21 | expect($log.error.logs.shift()).toEqual(['myError', 'comment']); 22 | }); 23 | }); 24 | }); 25 | -------------------------------------------------------------------------------- /test/ng/filter/orderBySpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('Filter: orderBy', function() { 4 | var orderBy; 5 | beforeEach(inject(function($filter) { 6 | orderBy = $filter('orderBy'); 7 | })); 8 | 9 | it('should return same array if predicate is falsy', function() { 10 | var array = [1, 2, 3]; 11 | expect(orderBy(array)).toBe(array); 12 | }); 13 | 14 | it('shouldSortArrayInReverse', function() { 15 | expect(orderBy([{a:15}, {a:2}], 'a', true)).toEqualData([{a:15}, {a:2}]); 16 | expect(orderBy([{a:15}, {a:2}], 'a', "T")).toEqualData([{a:15}, {a:2}]); 17 | expect(orderBy([{a:15}, {a:2}], 'a', "reverse")).toEqualData([{a:15}, {a:2}]); 18 | }); 19 | 20 | it('should sort array by predicate', function() { 21 | expect(orderBy([{a:15, b:1}, {a:2, b:1}], ['a', 'b'])).toEqualData([{a:2, b:1}, {a:15, b:1}]); 22 | expect(orderBy([{a:15, b:1}, {a:2, b:1}], ['b', 'a'])).toEqualData([{a:2, b:1}, {a:15, b:1}]); 23 | expect(orderBy([{a:15, b:1}, {a:2, b:1}], ['+b', '-a'])).toEqualData([{a:15, b:1}, {a:2, b:1}]); 24 | }); 25 | 26 | it('should use function', function() { 27 | expect( 28 | orderBy( 29 | [{a:15, b:1},{a:2, b:1}], 30 | function(value) { return value.a; })). 31 | toEqual([{a:2, b:1},{a:15, b:1}]); 32 | }); 33 | 34 | }); 35 | -------------------------------------------------------------------------------- /test/ng/localeSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$locale', function() { 4 | 5 | var $locale = new $LocaleProvider().$get(); 6 | 7 | it('should have locale id set to en-us', function() { 8 | expect($locale.id).toBe('en-us'); 9 | }); 10 | 11 | 12 | it('should have NUMBER_FORMATS', function() { 13 | var numberFormats = $locale.NUMBER_FORMATS; 14 | expect(numberFormats).toBeDefined(); 15 | expect(numberFormats.PATTERNS.length).toBe(2); 16 | angular.forEach(numberFormats.PATTERNS, function(pattern) { 17 | expect(pattern.minInt).toBeDefined(); 18 | expect(pattern.minFrac).toBeDefined(); 19 | expect(pattern.maxFrac).toBeDefined(); 20 | expect(pattern.posPre).toBeDefined(); 21 | expect(pattern.posSuf).toBeDefined(); 22 | expect(pattern.negPre).toBeDefined(); 23 | expect(pattern.negSuf).toBeDefined(); 24 | expect(pattern.gSize).toBeDefined(); 25 | expect(pattern.lgSize).toBeDefined(); 26 | }); 27 | }); 28 | 29 | 30 | it('should have DATETIME_FORMATS', function() { 31 | var datetime = $locale.DATETIME_FORMATS; 32 | expect(datetime).toBeDefined(); 33 | expect(datetime.DAY.length).toBe(7); 34 | expect(datetime.SHORTDAY.length).toBe(7); 35 | expect(datetime.SHORTMONTH.length).toBe(12); 36 | expect(datetime.MONTH.length).toBe(12); 37 | expect(datetime.AMPMS.length).toBe(2); 38 | }); 39 | 40 | 41 | it('should return correct plural types', function() { 42 | expect($locale.pluralCat(-1)).toBe('other'); 43 | expect($locale.pluralCat(0)).toBe('other'); 44 | expect($locale.pluralCat(2)).toBe('other'); 45 | expect($locale.pluralCat(1)).toBe('one'); 46 | }); 47 | }); 48 | -------------------------------------------------------------------------------- /test/ng/rootElementSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$rootElement', function() { 4 | it('should publish the bootstrap element into $rootElement', function() { 5 | var element = jqLite('
'); 6 | var injector = angular.bootstrap(element); 7 | 8 | expect(injector.get('$rootElement')[0]).toBe(element[0]); 9 | 10 | dealoc(element); 11 | }); 12 | }); 13 | -------------------------------------------------------------------------------- /test/ng/routeParamsSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$routeParams', function() { 4 | it('should publish the params into a service', function() { 5 | module(function($routeProvider) { 6 | $routeProvider.when('/foo', {}); 7 | $routeProvider.when('/bar/:barId', {}); 8 | }); 9 | 10 | inject(function($rootScope, $route, $location, $routeParams) { 11 | $location.path('/foo').search('a=b'); 12 | $rootScope.$digest(); 13 | expect($routeParams).toEqual({a:'b'}); 14 | 15 | $location.path('/bar/123').search('x=abc'); 16 | $rootScope.$digest(); 17 | expect($routeParams).toEqual({barId:'123', x:'abc'}); 18 | }); 19 | }); 20 | 21 | it('should correctly extract the params when a param name is part of the route', function() { 22 | module(function($routeProvider) { 23 | $routeProvider.when('/bar/:foo/:bar', {}); 24 | }); 25 | 26 | inject(function($rootScope, $route, $location, $routeParams) { 27 | $location.path('/bar/foovalue/barvalue'); 28 | $rootScope.$digest(); 29 | expect($routeParams).toEqual({bar:'barvalue', foo:'foovalue'}); 30 | }); 31 | }); 32 | 33 | it('should support route params not preceded by slashes', function() { 34 | module(function($routeProvider) { 35 | $routeProvider.when('/bar:barId/foo:fooId/', {}); 36 | }); 37 | 38 | inject(function($rootScope, $route, $location, $routeParams) { 39 | $location.path('/barbarvalue/foofoovalue/'); 40 | $rootScope.$digest(); 41 | expect($routeParams).toEqual({barId: 'barvalue', fooId: 'foovalue'}); 42 | }); 43 | }); 44 | }); 45 | -------------------------------------------------------------------------------- /test/ng/windowSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('$window', function() { 4 | it("should inject $window", inject(function($window) { 5 | expect($window).toBe(window); 6 | })); 7 | }); 8 | -------------------------------------------------------------------------------- /test/ngSanitize/directive/ngBindHtmlSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | 4 | describe('ngBindHtml', function() { 5 | beforeEach(module('ngSanitize')); 6 | 7 | it('should set html', inject(function($rootScope, $compile) { 8 | var element = $compile('
')($rootScope); 9 | $rootScope.html = '
hello
'; 10 | $rootScope.$digest(); 11 | expect(angular.lowercase(element.html())).toEqual('
hello
'); 12 | })); 13 | 14 | 15 | it('should reset html when value is null or undefined', inject(function($compile, $rootScope) { 16 | var element = $compile('
')($rootScope); 17 | 18 | angular.forEach([null, undefined, ''], function(val) { 19 | $rootScope.html = 'some val'; 20 | $rootScope.$digest(); 21 | expect(angular.lowercase(element.html())).toEqual('some val'); 22 | 23 | $rootScope.html = val; 24 | $rootScope.$digest(); 25 | expect(angular.lowercase(element.html())).toEqual(''); 26 | }); 27 | })); 28 | }); 29 | -------------------------------------------------------------------------------- /test/ngSanitize/filter/linkySpec.js: -------------------------------------------------------------------------------- 1 | describe('linky', function() { 2 | var linky; 3 | 4 | beforeEach(module('ngSanitize')); 5 | 6 | beforeEach(inject(function($filter){ 7 | linky = $filter('linky'); 8 | })); 9 | 10 | it('should do basic filter', function() { 11 | expect(linky("http://ab/ (http://a/) http://1.2/v:~-123. c")). 12 | toEqual('http://ab/ ' + 13 | '(http://a/) ' + 14 | '<http://a/> ' + 15 | 'http://1.2/v:~-123. c'); 16 | expect(linky(undefined)).not.toBeDefined(); 17 | }); 18 | 19 | it('should handle mailto:', function() { 20 | expect(linky("mailto:me@example.com")). 21 | toEqual('me@example.com'); 22 | expect(linky("me@example.com")). 23 | toEqual('me@example.com'); 24 | expect(linky("send email to me@example.com, but")). 25 | toEqual('send email to me@example.com, but'); 26 | }); 27 | 28 | it('should handle target:', function() { 29 | expect(linky("http://example.com", "_blank")). 30 | toEqual('http://example.com') 31 | expect(linky("http://example.com", "someNamedIFrame")). 32 | toEqual('http://example.com') 33 | }); 34 | }); 35 | -------------------------------------------------------------------------------- /test/ngScenario/ScenarioSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe("ScenarioSpec: Compilation", function() { 4 | var element; 5 | 6 | afterEach(function() { 7 | dealoc(element); 8 | }); 9 | 10 | 11 | describe('compilation', function() { 12 | it("should compile dom node and return scope", inject(function($rootScope, $compile) { 13 | var node = jqLite('
{{b=a+1}}
')[0]; 14 | element = $compile(node)($rootScope); 15 | $rootScope.$digest(); 16 | expect($rootScope.a).toEqual(1); 17 | expect($rootScope.b).toEqual(2); 18 | })); 19 | 20 | it("should compile jQuery node and return scope", inject(function($rootScope, $compile) { 21 | element = $compile(jqLite('
{{a=123}}
'))($rootScope); 22 | $rootScope.$digest(); 23 | expect(jqLite(element).text()).toEqual('123'); 24 | })); 25 | 26 | it("should compile text node and return scope", inject(function($rootScope, $compile) { 27 | element = $compile('
{{a=123}}
')($rootScope); 28 | $rootScope.$digest(); 29 | expect(jqLite(element).text()).toEqual('123'); 30 | })); 31 | }); 32 | }); 33 | -------------------------------------------------------------------------------- /test/ngScenario/e2e/Runner-compiled.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /test/ngScenario/e2e/Runner.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /test/ngScenario/e2e/style.css: -------------------------------------------------------------------------------- 1 | th { 2 | text-align: left; 3 | } 4 | 5 | tr { 6 | border: 1px solid black; 7 | } 8 | 9 | .redbox { 10 | background-color: red; 11 | } 12 | -------------------------------------------------------------------------------- /test/ngScenario/matchersSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('angular.scenario.matchers', function () { 4 | var matchers; 5 | 6 | function expectMatcher(value, test) { 7 | delete matchers.error; 8 | delete matchers.future.value; 9 | if (value !== undefined) { 10 | matchers.future.value = value; 11 | } 12 | test(); 13 | expect(matchers.error).toBeUndefined(); 14 | } 15 | 16 | beforeEach(function() { 17 | /** 18 | * Mock up the future system wrapped around matchers. 19 | * 20 | * @see Scenario.js#angular.scenario.matcher 21 | */ 22 | matchers = { 23 | future: { name: 'test' } 24 | }; 25 | matchers.addFuture = function(name, callback) { 26 | callback(function(error) { 27 | matchers.error = error; 28 | }); 29 | }; 30 | angular.extend(matchers, angular.scenario.matcher); 31 | }); 32 | 33 | it('should handle basic matching', function() { 34 | expectMatcher(10, function() { matchers.toEqual(10); }); 35 | expectMatcher('value', function() { matchers.toBeDefined(); }); 36 | expectMatcher([1], function() { matchers.toBeTruthy(); }); 37 | expectMatcher("", function() { matchers.toBeFalsy(); }); 38 | expectMatcher(0, function() { matchers.toBeFalsy(); }); 39 | expectMatcher('foo', function() { matchers.toMatch('.o.'); }); 40 | expectMatcher(null, function() { matchers.toBeNull(); }); 41 | expectMatcher([1, 2, 3], function() { matchers.toContain(2); }); 42 | expectMatcher(3, function() { matchers.toBeLessThan(10); }); 43 | expectMatcher(3, function() { matchers.toBeGreaterThan(-5); }); 44 | }); 45 | 46 | it('should have toHaveClass matcher', function(){ 47 | var e = angular.element('
'); 48 | expect(e).not.toHaveClass('none'); 49 | expect(e).toHaveClass('abc'); 50 | }); 51 | }); 52 | -------------------------------------------------------------------------------- /test/ngScenario/mocks.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | angular.scenario.testing = angular.scenario.testing || {}; 4 | 5 | angular.scenario.testing.MockAngular = function() { 6 | this.reset(); 7 | this.element = jqLite; 8 | }; 9 | 10 | angular.scenario.testing.MockAngular.prototype.reset = function() { 11 | this.log = []; 12 | }; 13 | 14 | angular.scenario.testing.MockAngular.prototype.poll = function() { 15 | this.log.push('$brower.poll()'); 16 | return this; 17 | }; 18 | 19 | angular.scenario.testing.MockRunner = function() { 20 | this.listeners = []; 21 | }; 22 | 23 | angular.scenario.testing.MockRunner.prototype.on = function(eventName, fn) { 24 | this.listeners[eventName] = this.listeners[eventName] || []; 25 | this.listeners[eventName].push(fn); 26 | }; 27 | 28 | angular.scenario.testing.MockRunner.prototype.emit = function(eventName) { 29 | var args = Array.prototype.slice.call(arguments, 1); 30 | angular.forEach(this.listeners[eventName] || [], function(fn) { 31 | fn.apply(this, args); 32 | }); 33 | }; 34 | -------------------------------------------------------------------------------- /test/ngScenario/output/jsonSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('angular.scenario.output.json', function() { 4 | var output, context; 5 | var runner, model, $window; 6 | var spec, step; 7 | 8 | beforeEach(function() { 9 | $window = {}; 10 | context = _jQuery('
'); 11 | runner = new angular.scenario.testing.MockRunner(); 12 | model = new angular.scenario.ObjectModel(runner); 13 | output = angular.scenario.output.json(context, runner, model); 14 | spec = { 15 | name: 'test spec', 16 | definition: { 17 | id: 10, 18 | name: 'describe' 19 | } 20 | }; 21 | step = { 22 | name: 'some step', 23 | line: function() { return 'unknown:-1'; } 24 | }; 25 | }); 26 | 27 | it('should put json in context on RunnerEnd', function() { 28 | runner.emit('SpecBegin', spec); 29 | runner.emit('StepBegin', spec, step); 30 | runner.emit('StepEnd', spec, step); 31 | runner.emit('SpecEnd', spec); 32 | runner.emit('RunnerEnd'); 33 | 34 | expect(angular.fromJson(context.html()).children['describe'] 35 | .specs['test spec'].status).toEqual('success'); 36 | }); 37 | }); 38 | -------------------------------------------------------------------------------- /test/ngScenario/output/objectSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('angular.scenario.output.object', function() { 4 | var output; 5 | var runner, model, $window; 6 | var spec, step; 7 | 8 | beforeEach(function() { 9 | $window = {}; 10 | runner = new angular.scenario.testing.MockRunner(); 11 | model = new angular.scenario.ObjectModel(runner); 12 | runner.$window = $window; 13 | output = angular.scenario.output.object(null, runner, model); 14 | spec = { 15 | name: 'test spec', 16 | definition: { 17 | id: 10, 18 | name: 'describe', 19 | children: [] 20 | } 21 | }; 22 | step = { 23 | name: 'some step', 24 | line: function() { return 'unknown:-1'; } 25 | }; 26 | }); 27 | 28 | it('should create a global variable $result', function() { 29 | expect($window.$result).toBeDefined(); 30 | }); 31 | 32 | it('should maintain live state in $result', function() { 33 | runner.emit('SpecBegin', spec); 34 | runner.emit('StepBegin', spec, step); 35 | runner.emit('StepEnd', spec, step); 36 | 37 | expect($window.$result.children['describe'] 38 | .specs['test spec'].steps[0].duration).toBeDefined(); 39 | }); 40 | }); 41 | -------------------------------------------------------------------------------- /test/ngScenario/output/xmlSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | describe('angular.scenario.output.xml', function() { 4 | var output, context; 5 | var runner, model, $window; 6 | var spec, step; 7 | 8 | beforeEach(function() { 9 | $window = {}; 10 | context = _jQuery('
'); 11 | runner = new angular.scenario.testing.MockRunner(); 12 | model = new angular.scenario.ObjectModel(runner); 13 | output = angular.scenario.output.xml(context, runner, model); 14 | spec = { 15 | name: 'test spec', 16 | definition: { 17 | id: 10, 18 | name: 'describe' 19 | } 20 | }; 21 | step = { 22 | name: 'some step', 23 | line: function() { return 'unknown:-1'; } 24 | }; 25 | }); 26 | 27 | it('should create XML nodes for object model', function() { 28 | runner.emit('SpecBegin', spec); 29 | runner.emit('StepBegin', spec, step); 30 | runner.emit('StepEnd', spec, step); 31 | runner.emit('SpecEnd', spec); 32 | runner.emit('RunnerEnd'); 33 | expect(context.find('it').attr('status')).toEqual('success'); 34 | expect(context.find('it step').attr('status')).toEqual('success'); 35 | }); 36 | 37 | it('should output errors to the XML', function() { 38 | runner.emit('SpecBegin', spec); 39 | runner.emit('StepBegin', spec, step); 40 | runner.emit('StepFailure', spec, step, 'error reason'); 41 | runner.emit('StepEnd', spec, step); 42 | runner.emit('SpecEnd', spec); 43 | runner.emit('RunnerEnd'); 44 | 45 | expect(context.find('it').attr('status')).toEqual('failure'); 46 | expect(context.find('it step').attr('status')).toEqual('failure'); 47 | expect(context.find('it step').text()).toEqual('error reason'); 48 | }); 49 | }); 50 | -------------------------------------------------------------------------------- /test/unit/controllersSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* jasmine specs for controllers go here */ 4 | 5 | describe('controllers', function(){ 6 | beforeEach(module('myApp.controllers')); 7 | 8 | 9 | it('should ....', inject(function() { 10 | //spec body 11 | })); 12 | 13 | it('should ....', inject(function() { 14 | //spec body 15 | })); 16 | }); 17 | -------------------------------------------------------------------------------- /test/unit/directivesSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* jasmine specs for directives go here */ 4 | 5 | describe('directives', function() { 6 | beforeEach(module('myApp.directives')); 7 | 8 | describe('app-version', function() { 9 | it('should print current version', function() { 10 | module(function($provide) { 11 | $provide.value('version', 'TEST_VER'); 12 | }); 13 | inject(function($compile, $rootScope) { 14 | var element = $compile('')($rootScope); 15 | expect(element.text()).toEqual('TEST_VER'); 16 | }); 17 | }); 18 | }); 19 | }); 20 | -------------------------------------------------------------------------------- /test/unit/filtersSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* jasmine specs for filters go here */ 4 | 5 | describe('filter', function() { 6 | beforeEach(module('myApp.filters')); 7 | 8 | 9 | describe('interpolate', function() { 10 | beforeEach(module(function($provide) { 11 | $provide.value('version', 'TEST_VER'); 12 | })); 13 | 14 | 15 | it('should replace VERSION', inject(function(interpolateFilter) { 16 | expect(interpolateFilter('before %VERSION% after')).toEqual('before TEST_VER after'); 17 | })); 18 | }); 19 | }); 20 | -------------------------------------------------------------------------------- /test/unit/servicesSpec.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* jasmine specs for services go here */ 4 | 5 | describe('service', function() { 6 | beforeEach(module('myApp.services')); 7 | 8 | 9 | describe('version', function() { 10 | it('should return current version', inject(function(version) { 11 | expect(version).toEqual('0.1'); 12 | })); 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /version.yaml: -------------------------------------------------------------------------------- 1 | # AngularJS build config file 2 | --- 3 | version: 1.1.5-snapshot 4 | codename: triangle-squarification 5 | stable: 1.1.4 6 | -------------------------------------------------------------------------------- /watchr-docs.rb: -------------------------------------------------------------------------------- 1 | # config file for watchr http://github.com/mynyml/watchr 2 | # install: gem install watchr 3 | # run: watch watchr-docs.rb 4 | 5 | watch( '^src/|^docs/' ) do 6 | system 'echo "\n\ndoc run started @ `date`"; node docs/src/gen-docs.js' 7 | end 8 | --------------------------------------------------------------------------------