Commit Graph

29 Commits (3340364802a8cdcc5f4145fbde2a5dd4f7087771)

Author SHA1 Message Date
David Fischer 1f55b3a89d
Updates for the manifest storage
- Fix missing file references with a symlink
- Fix missing font
2018-07-25 12:21:47 -07:00
David Fischer a63702e2a3 Fix missing fonts (#4060) 2018-05-22 10:46:43 -06:00
Anthony Johnson 57da05b386
Fix broken dependency for gulp build
vinyl-source-stream was causing problems. This updates the package and reruns
gulp build.
2017-11-04 01:15:03 -06:00
CM Lubinski 9e07061730 Add eslint using the airbnb config. (#2905)
* Add eslint using the airbnb config.

In an effort to make the JS consistent, this adds an ESLint gulp task. ESLint
is *very* configurable, and has no defaults. Instead, this reaches for
airbnb's legacy config (which covers ES5), which is one of the most popular
configurations. As a last step, it turns off all of the rules which currently
fail. We can turn them on piecemeal, or override the airbnb style to use a
different format.

Rules to prioritize (as they likely indicate bugs):
* "array-callback-return": "off",
* "eqeqeq": "off",
* "guard-for-in": "off",
* "no-inner-declarations": "off",
* "no-loop-func": "off",
* "no-mixed-operators": "off",
* "no-undef": "off",
* "no-use-before-define": "off",
* "one-var": "off",

* Lint frontend in Travis.

This adds an ESLint step to the CI service so we prevent unlinted code from
making its way in.

* Create an ESLint tox env.

By adding a tox env for eslint, we allow users to run it locally as part of
tox runs.

Thanks for the suggestion @ericholscher!

* Fix tox call to gulp lint task
2017-05-24 16:12:33 -07:00
Anthony 285bbf13f6 Integrate on-site messaging that is persistent, combine message transports (#2406)
* WIP for integrating persistent messaging for users

Combines notifications so that email/on site messaging will all be maintained in
the same place, and can extend from each other using normal template semantics.

* Add email support, clean up implementation

* Add reqs

* Drop unnecessary string conversion

* Change admin email form to look at templates, not ask for template source

* Add docs, tests, views for processing redirects

* Do the thing I meant to do

* Drop views, just use javascript instead

This adds javascript that intercepts link clicks in notifications,
hits the dismiss url defined on the dom object, and then redirects 
to the correct url of the original link.

* Move classes around and rename module

* Drop unused notification for testing

* Clean up usage, drop test uses of the views/notifications

* Add example usage that will be used for notification on resource usage

* Fix mock module path

* Add more docs around implementation
2016-10-01 10:19:51 -07:00
Anthony Johnson 87a6e44869 Add a per-project advertising opt-out, and form page for preference
This adds a per-project advertising opt-out form, with some guidance on supporting
Read the Docs if you oppose advertising. It links to several pages explaining more
about the advertising spot, how to opt-out of ads, and a backup option to just
remove ads altogether if you don't want to support the project.
2016-03-09 15:11:10 -08:00
Anthony Johnson 988860b19e Update javascript include paths in gulpfile 2015-09-28 10:03:53 -07:00
Anthony Johnson 61da2fb15d Move projectimport to projects app 2015-09-24 18:23:41 -07:00
Anthony Johnson 6141c79832 Redo html layout and add styling to import page 2015-09-24 18:23:41 -07:00
Anthony Johnson 89a9481929 Use font files from bower sources 2015-09-10 16:23:03 -07:00
Anthony Johnson c9c17ee924 Replace vendored theme CSS with bower package support
Gulp will copy these files into our vendored sources from now on,
installing from the sphinx_rtd_theme github repo.
2015-09-10 15:09:09 -07:00
Anthony Johnson 26f27ddd77 Prefix application bundles with application name
This will allow `projects/js/tools.js` to be imported with
`require('projects/tools')`
2015-08-26 12:22:17 -07:00
Anthony Johnson ae12289182 Gulpfile less watch 2015-08-25 11:55:40 -07:00
Anthony Johnson 9e86e69138 And standalone bundles for legacy javascript usage 2015-08-24 22:59:39 -07:00
Anthony Johnson d8bd1742dc Generate rtd doc embed js without creating a module 2015-08-24 01:35:13 -07:00
Anthony Johnson e45955945b Generate vendor libs that aren't `standalone`
It seems standalone libs will either export globally or via
require, but not both? Removing standalone and requiring jquery
in the base template creates a global instance of jquery.
2015-08-23 12:16:13 -07:00
Anthony Johnson 22db8f3d3d Add base javascript for build detail 2015-08-19 16:26:51 -07:00
Gregor Müllegger b41c9a64a9 Move django-csrf.js and rtd-import.js into core's static-src directory 2015-08-06 13:43:37 +02:00
Eric Holscher 0657014884 Use proper static serving for Javascript 2015-08-05 10:55:55 -07:00
Eric Holscher 44164796bd Fix manage.py link in gulp 2015-07-30 15:47:38 -07:00
Anthony Johnson 102652584b Fix gulpfile watch logic issue
Watch all js/css in static-src, not just entry points
2015-07-30 14:09:49 -07:00
Anthony Johnson a8c2d8e9a8 Change gulpfile execution of django project
Fixes issue #1490
2015-07-27 11:07:32 -07:00
Anthony Johnson 12b142a352 Make vendor libraries standalone
This makes vendor libraries expose exports via `require` and also globally in
the `window` context. This is required for directly using modules like jquery
from an script include in html.
2015-07-21 23:53:25 -07:00
Anthony Johnson 25a9ef380a More cleanup 2015-07-21 23:53:25 -07:00
Anthony Johnson 2dedf2781b Standardize and document front end development procedures
* Docs!
* Updated gulpfile, ported changes to corporate gulpfile back here. Changes here include:
  * New browserify syntax, dropped banned gulp-browserify module
  * Broke out jquery and knockout to standalone vendor packages. Client libraries were bundled with these before. Now, templates that include the client libraries are also responsible for including vendor dependencies
  * Vendor libraries are passed through Browserify to provide both global window access as normal, and access to the module via require
  * Ported better structure and better watch file support
  * Added minifying to javascript and vendor javascript
* Regenerated javascript libraries as minified files
* Added readthedocs/static/vendor path for checked in vendor files
* Adds static file dir for generic readthedocs/static path
* Replaces google CDN jquery with vendored jquery, still v2.0.3
* Pinned bower jquery dependency at 2.0.3
2015-07-21 23:53:25 -07:00
Anthony Johnson 56ea87f6a1 Add site url and logo url to donate page output
Breaks up javascript into inherited views, based on core/payment.js. Adds a
migration to add the two fields.
2015-04-16 13:46:03 -07:00
Anthony Johnson a7847a49de Rework gold UI with knockout and payment UI plugin
Use knockout to get gold forms closer to single page. Use payment UI plugin for
jquery to make forms less shitty.
2015-04-07 18:23:11 -07:00
Anthony Johnson 59a29e63c5 Starting to move javascript out of template for tools 2015-02-26 12:02:32 -08:00
Anthony Johnson acc7308715 Add toolchain for front end js/css and basic bits for ads 2015-02-12 14:19:36 -08:00